Polycarp's phone book

Problem Name:
Polycarp's phone book
Site:CodeForces
Links:
Tags:
Problem setters: