2 comments

[ 3.8 ms ] story [ 13.4 ms ] thread
a variation of bubble sort, so O(N^2)
I think it's more a variation on Selection Sort. I agree on O(n*n)