IBM interview question

Reverse a array in place