Guest User

Untitled

a guest
Jun 24th, 2018
85
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.18 KB | None | 0 0
  1. def insertion_sort(a):
  2. for i in range(1,len(a)):
  3. x = a[i]
  4. j = i-1
  5. while(j>-1) and x <a[j]:
  6. a[j+1] = a[j]
  7. j=j-1
  8. a[j+1] = x
Add Comment
Please, Sign In to add comment