Rosetta Problems

Free Contest 16 - SHELF2

https://oj.vnoi.info/problem/fc016_shelf2