find the greatest common divisor

function gcd(a, b)
    if b = 0
       return a
    else
       return gcd(b, a mod b)

 

posted @ 2014-11-13 12:56  zmiao  阅读(121)  评论(0编辑  收藏  举报