Anonymous user
Heronian triangles: Difference between revisions
m
→{{header|REXX}}: changed the calculation of digits (for precision) to handle different interpretations of numeric precision (using trailing zeroes).
(→{{header|REXX}}: eliminated the need for a (true) SQRT subroutine, used an integer version (iSQRT) instead; it made the Heronian program four times faster.) |
m (→{{header|REXX}}: changed the calculation of digits (for precision) to handle different interpretations of numeric precision (using trailing zeroes).) |
||
Line 686:
if first=='' | first==',' then first= 10 /* " " " " */
if area=='' | area==',' then area=210 /* " " " " */
numeric digits 99; numeric digits max(9, 1+length(N**
call Heron /*invoke Heron subroutine. */
say # ' primitive Heronian triangles found with sides up to ' N " (inclusive)."
|