MathDB
Moving k-th book to the k-th position

Source: Canadian MO 2012

May 4, 2012
inductioninequalitiescombinatorics

Problem Statement

A bookshelf contains nn volumes, labelled 11 to nn, in some order. The librarian wishes to put them in the correct order as follows. The librarian selects a volume that is too far to the right, say the volume with label kk, takes it out, and inserts it in the kk-th position. For example, if the bookshelf contains the volumes 1,3,2,41,3,2,4 in that order, the librarian could take out volume 22 and place it in the second position. The books will then be in the correct order 1,2,3,41,2,3,4.
(a) Show that if this process is repeated, then, however the librarian makes the selections, all the volumes will eventually be in the correct order. (b) What is the largest number of steps that this process can take?