changed pythagorean triplet solution to massively more efficient one