Skip to content

Commit 4b907b4

Browse files
Update gcd.c
1 parent 89ef4be commit 4b907b4

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

gcd.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,9 +50,9 @@ int gcd(int a, int b)
5050
a = b;
5151
b = temp;
5252
}
53-
//Base Case is when a equals 0, this tells we are done
53+
//Base Case is when a equals 0, this tells we are done (From:"Keep repeating the step until one of the two numbers reaches zero")
5454
if(a == 0)
5555
return b;
56-
else // Else return our recursive case
56+
else // Else return our recursive case (From: repeatedly replace the larger number with the greater number mod the lesser number)
5757
return gcd(a, b%a);
5858
}

0 commit comments

Comments
 (0)