Solutions for the codeeval challenges