My code for google codejam 2014