Greedy algorithm for Egyptian fractions: Difference between revisions
Greedy algorithm for Egyptian fractions (view source)
Revision as of 15:20, 5 September 2020
, 3 years ago→{{header|ALGOL 68}}: typo in comment, doh!
(Added Algol 68) |
(→{{header|ALGOL 68}}: typo in comment, doh!) |
||
Line 48:
Uses Algol 68G's LONG LONG INT for large integers.
<lang algol68>BEGIN # compute some Egytian fractions #
PR precision 2000 PR # set the number of digits for LONG
PROC gcd = ( LONG LONG INT a, b )LONG LONG INT:
IF b = 0 THEN
|