My Google Code Jam 2014 Quals responses (B is crappy, C and D may solve large inputs)