I. 107. Suppose that there is an array with m+n elements in the memory (m and n are positive integers). Your task is to interchange the first n elements of the array with the last m elements - without using up any more memory. (The usage of some auxiliary variables is, however, allowed.) Neither the ordering of the first n elements, nor that of the last m elements should change during the process.
The precise and detailed description of your algorithm is to be submitted (i107.txt, together with the spreadsheet computing typical values of the auxiliary variables (i107.xls).
Deadline expired on 15 June 2005.