Yet Another Bookshelf

Problem Name:
Yet Another Bookshelf
Site:CodeForces
Links:
Tags:
Problem setters: