Solutions for various Kattis problems.