Special pythagorean triplet: Difference between revisions

→‎{{header|Raku}}: return the product as well
m (→‎{{header|ALGOL 68}}: Remove test for solution found)
(→‎{{header|Raku}}: return the product as well)
Line 278:
my $c = 1000 - $a - $b;
last if $c < $b;
say "$a² + $b² = $c²\n$a + $b + $c = 1000"{$a+$b+$c}\n$a and exit if× $a2b + × $c == {$a×$b×$c²}"
and exit if $a2 + $b² == $c²
}
}</lang>
{{out}}
<pre>200² + 375² = 425²
200 + 375 + 425 = 1000</pre>
200 × 375 × 425 = 31875000</pre>
 
=={{header|REXX}}==
10,333

edits