You are on page 1of 4

BCY-Entry-Combo-Solutions

Mahdi Mahi
November 16, 2022

§1 USAMO 2005/1
It’s easy to see that the product of two distinct primes doesn’t work. We will show that
all other composite numbers work.
ˆ If n is a power of a prime, this is clear.
ˆ If n = pe11 . . . pekk for some k ≥ 3, then first place p1 p2 , p2 p3 , . . . , pk p1 on the circle.
Then we can arbitrarily place any multiples of pi between pi−1 pi and pi pi+1 .
ˆ If n = pa q b , where a and b are not both equal to 1, we can first place pq and pa q b
and then place multiples of p in one arc and multiples of q in the other arc.

§2 Canada 2018/1
If the number of tokens is a power of 2, then it is collapsible. The proof follows by
induction. The base case n = 1 is obvious. Now, assume that there exists integer i such
that this result holds for k = i. For the case n = 2k+1 , we first arbitrarily partition the
tokens into two groups of 2k and collapse those. Now, we just collapse each of the 2k
pairs of tokens in different sets.
Now we show that no other n works. Assume we place one token at (1, 0) and all other
tokens in the origin of the cartesian plane. Notice that the sum of the x coordinates of the
tokens is an invariant. In a collaped arrangement, all the tokens must have x-coordinates
equal to n1 . Also notice that after every move, the x-coordinates of the tokens must have
a power of 2 in the denominator (because we take the average of two x-coordinates).
Thus n must be a power of 2, a contradiction.

§3 Argentina TST 2011


This is only possible for party B.

Notice that every time three persons from distinct parties interact, the number of
people in each party decreases by 1 modulo 4. Since the desired position is 0, 0, 0, 1
(mod 4) is some order, it’s easy to see that the only possibility is B. Now we show that
the position is indeed achievable. Consider the process:

(a, b, c, d) − − − (a − 1, b − 1, c + 3, d − 1) − − − (a − 2, b − 2, c + 2, d + 2)
− − −(a + 1, b − 3, c + 1, d + 1) − − − (a + 4, b − 4, c, d)
We can run it twice to (28, 31, 23, 19) to get (36, 23, 23, 19) and in the next turn we get
(35, 22, 22, 22). Now we can easily reach the desired position.

1
Mahdi Mahi (November 16, 2022) BCY-Entry-Combo-Solutions

§4 PAGMO 2021/1
The answer is all even n.
Notice that a valid path must visit n after visiting all other coins. The total distance
traveled before reaching n is 1 + 2 + · · · + (n − 1) = 12 n(n − 1). When n is odd, the total
distance is a multiple of n, so that’s impossible as 1 and n don’t occupy the same place.
When n is even, we can place 1, n − 2, n − 4, . . . , 2, n, n − 1, n − 3, . . . , 3 in the clockwise
direction where 1 and n are situated in diametrically opposite places and the odd and
even numbers are placed along two different arcs.

§5 Tuymaada 2018/J6
The answer is any value in the set

S = {0, 2, 4, . . . , 1022}

First note that the final number should have the same parity as 0 + 1 + · · · + 1024 ≡ 0
(mod 2) and should be strictly less than 1024. Now let 1 ≤ m ≤ 1023 be odd and consider
the pairs (1, 2), (3, 4), . . . , (m − 2, m − 1), (1024, m), (m + 1, m + 2), (m + 3, m + 4), . . . ,
(1022, 1023). After the first turn we are left with 1024 − m and 511 copies of 1. On the
next turn we must get 1023 − m and several zeros, and from there we find a final result
of 1023 − m. Thus, we can get any value in the mentioned set.

§6 JBMO Shortlist 2018 C3


The answer is 13.
For n ≤ 12 , Alice loses because Bob can color the most populated rows, eliminating at
least 8 red squares, and easily cover the other four.
Alice can win when n = 13 by the following coloring (1 and 0 refers to red and white):
1 0 0 0 0 0 0 0
0 1 0 0 0 0 0 0
0 0 1 0 0 0 0 0
0 0 0 1 0 0 0 1
0 0 0 1 1 0 0 0
0 0 0 0 1 1 0 0
0 0 0 0 0 1 1 0
0 0 0 0 0 0 1 1

§7 ELMO 1999/2
Let (x, y) be good if x + y 6= 0 (mod 5) and bad otherwise. Notice that one can only
reach good points from good points. Thus the desired conclusion is not possible.

§8 19LEULER
We consider all the numbers modulo 3. We want at least 700 identical residues. Initially,
there are 333 copies of 0 and 2 and 334 copies of 1. Now

ˆ Clearly we can’t get any more copies of 0.

2
Mahdi Mahi (November 16, 2022) BCY-Entry-Combo-Solutions

ˆ In order to maximize the number of 1’s we use 02 + 22 = 1 (mod 3) to get a total


of 667 copies of 1’s and 333 copies of 0.
ˆ In order to maximize the number of 2’s we use 12 + 22 = 2 (mod 3) and convert all
1’s to 2’s to get 667 copies of 2 and 333 copies of 0.

So we can’t get 700 identical numbers.

§9 Cyberspace Competition 2020/5


Claim — If we can reach (a1 , a2 , . . . , an ) from the starting position then we can
also reach (|a1 |, . . . , |an |).

Proof. THe proof follows by downwards induction. The base case n = 2020 is clear since
we start with only positive numbers. Now, suppose we can reach
(a1 , . . . , an−1 , x, y) → (a1 , . . . , an−1 , z)
where z is formed from x and y. We want to show |z| can be formed from |x| and |y|.
ˆ If z ∈ {xy, x/y, y/x} this is clear.
ˆ If z = x + y then note that
|x + y| ∈ {|x| + |y|, |x| − |y|, |y| − |x|}
regardless of what x and y are.

§10 Z4E655CD
Q
The answer is 101! − 1 since the product i (xi + 1) is an invariant.

§11 USAMTS 4/1/31


Label the person with 2019 mangoes person 0, and then label all the people successively
up to 99 going to the right, so that person 1 is right of person 0, person 2 is right of
person 1, and so on until person 0 is right of person 99. Let mi denote how many mangoes
person i has.

Claim — The quantity


99
X
N := mi 2i (mod 2100 − 1)
i=0

is invariant.

Proof. If person i eats, then mi decreases by 2 and mi+1 increases by 1, yielding a net
change of −2 · 2i + 1 · 2i+1 ≡ 0, so eating is invariant.
If person i shares, then mi decreases by 3, mi−1 increases by 2, and mi+1 increases by
1. This has a net change of
−3 · 2i + 2 · 2i−1 + 1 · 2i+1 ≡ 0,
so sharing is invariant too.

3
Mahdi Mahi (November 16, 2022) BCY-Entry-Combo-Solutions

At the Pbeginning of the process the invariant is N = 2019 · 20 = 2019. Therfore we


conclude 99 i
i=0 mi 2 = 2019. Because mi is either 0 or 1 at the end of the process, mi
must correspond to the binary digits of 2019, which is 111111000112 , which has 8 nonzero
binary digits which is equivalent to 8 people with mangoes left.

§12 Shortlist 2009 C1


Interpret gold as 1 and black as 0. The answer to (a) is yes, since interpreting the number
as a binary string of length 2009 we find that it decreases at each step.
Now for (b), we claim that

Claim — The second player must win regardless of what moves occur.

Proof. Consider the 10th, 60th, 110th card, and so on, up to the 1960th card from the
left. Denote the set of these 40 cards by C.
The number of 1’s in C must change by exactly 1 every turn, and it is initially 40.
The game could only end when all cards in C are zero. So this can only occur on the
first player’s turn.

You might also like