Rosetta Problems

IOIOI カード占い

https://atcoder.jp/contests/joisc2015/tasks/joisc2015_d