project-euler

Special Pythagorean triplet

Problem Description

A Pythagorean triplet is a set of three natural numbers, a < b < c, for which,

a² + b² = c²

For example, 3² + 4² = 9 + 16 = 25 = 5².

There exists exactly one Pythagorean triplet for which a + b + c = 1000.

Find the product abc.

Performance

Try it online!

Real time: 0.532 s
User time: 0.395 s
Sys. time: 0.144 s
CPU share: 101.48 %
Exit code: 0