I'm trying to solve problem Game of Cards from SWERC-2015.
I guess, that this game is equivalent to Nim game. I calculated the Sprague-Grandy value frome every pile of cards and counted xor of them.
Unfortunately, my solution gets WA on 7 test.
Please, help me with this problem.