Jump to content

Greatest common divisor: Difference between revisions

m (sub-header changes for Sidef solutions)
Line 1,516:
gcd(n, m) = (x asa x*y eq 0) fby eod;
end</lang>
 
=={{header|Luck}}==
<lang luck>function gcd(a: int, b: int): int = (
if a==0 then b
else if b==0 then a
else if a>b then gcd(b, a % b)
else gcd(a, b % a)
)</lang>
 
=={{header|Maple}}==
Anonymous user
Cookies help us deliver our services. By using our services, you agree to our use of cookies.