MathDB
Problems
Contests
National and Regional Contests
Pakistan Contests
Pakistan TST
2017 Pakistan TST
Problem 2
Problem 2
Part of
2017 Pakistan TST
Problems
(1)
Switching students in a circle, due to height.
Source: Pakistan TST (2) 2017. P2
1/28/2017
There are
n
n
n
students in a circle, one behind the other, all facing clockwise. The students have heights
h
1
<
h
2
<
h
3
<
⋯
<
h
n
h_1 <h_2 < h_3 < \cdots < h_n
h
1
<
h
2
<
h
3
<
⋯
<
h
n
. If a student with height
h
k
h_k
h
k
is standing directly behind a student with height
h
k
−
2
h_{k-2}
h
k
−
2
or lesss, the two students are permitted to switch places Prove that it is not possible to make more than
(
n
3
)
\binom{n}{3}
(
3
n
)
such switches before reaching a position in which no further switches are possible.
combinatorics
algorithm