Skip to content

Latest commit

 

History

History
27 lines (15 loc) · 540 Bytes

README.md

File metadata and controls

27 lines (15 loc) · 540 Bytes

InsertionSortProject

[22,27,16,2,18,6] dizinin insertion sort türüne göre asamalari

2,27,16,22,18,6 ->(n-1)

2,6,16,22,18,27 ->(n-2)

2,6,16,18,22,27 ->1

Big-O gösterimi: n(n+1)/2 O(n^2) 18 sayisi Average Case

Time Complexity:

Average Case: Aradigimiz sayinin ortada olma durumu

Worst Case: Aradigimiz sayinin sonda olma durumu

Best Case: Aradigimiz sayinin en basta olma durumu

[7,3,5,8,2,9,4,15,6] Dizisinin Insertion Sort'a göre ilk 4 adimi

2,3,5,8,7,9,4,15,6

2,3,4,8,7,9,5,15,6

2,3,4,5,7,9,8,15,6

2,3,4,5,6,9,8,15,7