Marvolo Gaunt's Ring

Problem Name:
Marvolo Gaunt's Ring
Site:CodeForces
Links:
Tags:
Problem setters: