Valeo Interview Question

Write a function to sort an array of numbers.

Interview Answer

Anonymous

Jun 25, 2016

bubble sort algorithm for(i=0;iarr[j+1]) // swap { tmp=arr[j]; arr[j]=arr[j+1]; arr[j+1]=tmp; } } }

1