# Greatest common divisor

(Redirected from Gcd)
The GCD of any two positive integers can be defined as a recursive function: ${\displaystyle gcd(u,v)={\begin{cases}gcd(v,u{\mbox{ mod }}v),&{\mbox{if }}v>0\\u,&{\mbox{if }}v=0\end{cases}}}$