def gcd(*numbers):
    """Euclid's algorithm for GCD. Arguments are cast to integer."""
    def gcd2(a,b):
        a=abs(int(a))
        b=abs(int(b))
        a,b = max(a,b), min(a,b)
        while b>0:
            a,b=b,a%b
        return a
    if len(numbers)==0:
        return 1
    res=numbers[0]
    for n in numbers[1:]:
        res=gcd2(n,res)
    return res