Sollicitatievraag bij Smarkets

Reverse an array.

Antwoord op sollicitatievraag

Anoniem

19 apr 2018

Did it in O(n) without an additional data structure. Loop through half of the array and use a temp variable to swap values.