Created Think Like a programmer solution