Goat on a Rope

Problem Name:
Goat on a Rope
Site:CodeForces
Links:
Tags:
Problem setters: