InterviewSolution
Saved Bookmarks
| 1. |
How many swaps are required for reversing an array having n elements where n is an odd number?(a) (n-1) / 2(b) n/2(c) (n/2) – 1(d) (n+1)/2My question is from Arrays Types topic in portion Arrays Types of Data Structures & Algorithms IThe question was asked in an interview. |
|
Answer» The correct choice is (a) (n-1) / 2 |
|