First go at squares exercise, all tests passing