add info gcd

This commit is contained in:
Rohit Tanwar
2018-01-21 12:32:41 +05:30
parent 3266885fc0
commit 24ade51ca4
2 changed files with 4 additions and 0 deletions

View File

@ -1,5 +1,7 @@
### gcd
:information_source: `math.gcd` works with only two numbers
Calculates the greatest common divisor between two or more numbers/lists.
The `helperGcdfunction` uses recursion. Base case is when `y` equals `0`. In this case, return `x`. Otherwise, return the GCD of `y` and the remainder of the division `x/y`.