Created
November 7, 2014 12:47
-
-
Save shellsong/c1150852cd1f11d86e59 to your computer and use it in GitHub Desktop.
greatest common divisor
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function gcd(a,b){ | |
return b>0?gcd(b,a%b):a; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment