Three Bikes
Chef and two of his friends are going on a biking trip this new year. They decided to rent three bikes from a shop. The shop has $N$ bikes, the $i$-th of which has a mileage of $M_i$. Chef and friends decided that they would rent three *distinct* bikes $i, j, k$ satisfying the following property: $$(M_i \oplus M_j) \mathbin{\&} M_k = M_i \oplus (M_j \mathbin{\&} M_k)$$ where $\oplus$ denotes [b
HINT LADDERno hints yet
L1 Observation
L2 Technique
L3 Approach
L4 Pseudo-code
🔒
L5 Full solution
L5 unlocks only if you insist twice
solution.cppC++17
CodeSearch Tutor
Hints, not spoilers — it won’t hand over the full solution unless you insist.
Sign in to chat with the tutor and save your progress.
Sign in to start