Pythagorean triple fixed by yvl

3.upto(?d){|a|3.upto(a*50){|b|c=(a*a+b*b)**0.5
puts [a,b,c]*" "if c==c=c.to_i}}

Note that non-ascii characters in the above source code will be escaped (such as \x9f).

download

return to the top page