Malam Team Israel interview question

how rotate a array in the sortest way

Interview Answer

Anonymous

19 Dec 2024

a loop till n/2 for each element to switch with the n-i element like the first element sould swithe with the last the second with the elemet in n-1 place