← All problemsSign in

Gems on the Bangle

Sneha has a bangle on which there are n even-spaced gems. There is a microscopic number written on each gem in the bangle. You are supposed to choose a positive real number h. Then you may repeatedly select 2 or more gems that are evenly-spaced and make a set. Then increase all numbers on gems by h or decrease all numbers by h. Would you eventually end up with all numbers equal to 0. Is it poss

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.

voice by Sarvam AI

Sign in to chat with the tutor and save your progress.

Sign in to start