Rosetta Problems

The Maximum Number of Overlaps

https://onlinejudge.u-aizu.ac.jp/problems/DSL_5_B