Project Euler #223: Almost right-angled triangles I