ADAMATCH spoj
https://www.spoj.com/problems/ADAMATCH/
How to solve this problem?
CodeChef Starters 131 Solution Discussion