String Magic
CodeChefOpen on judge ↗
Zeus challenged his son Rubixius with a puzzle in which he presented a line of text which was modified on saying some magic words. Zeus asked him to keep track of the mutations and answer the current text in the string whenever asked. Zeus wanted Rubixius to answer if any of these conditions held true. The conditions are prioritized with the first having highest priority. 1. Only answer if the s
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