def igcd(*args):
 if (len(args) < 2):
  raise TypeError(('igcd() takes at least 2 arguments (%s given)' % len(args)))
 if (1 in args):
  a = 1
  k = 0
 else:
  a = abs(as_int(args[0]))
  k = 1
 if (a != 1):
  while (k < len(args)):
   b = args[k]
   k += 1
   try:
    a = _gcdcache[(a, b)]
   except KeyError:
    b = as_int(b)
    if (not b):
     continue
    if (b == 1):
     a = 1
     break
    if (b < 0):
     b = (- b)
    t = (a, b)
    while b:
     (a, b) = (b, (a % b))
    _gcdcache[t] = _gcdcache[(t[1], t[0])] = a
 while (k < len(args)):
  ok = as_int(args[k])
  k += 1
 return a

def igcd ( * args ) : if ( len ( args ) < 2 ) : raise TypeError ( ( 'igcd() takes at least 2 arguments (%s given)' % len ( args ) ) ) if ( 1 in args ) : a = 1 k = 0 else : a = abs ( as_int ( args [ 0 ] ) ) k = 1 if ( a != 1 ) : while ( k < len ( args ) ) : b = args [ k ] k += 1 try : a = _gcdcache [ ( a , b ) ] except KeyError : b = as_int ( b ) if ( not b ) : continue if ( b == 1 ) : a = 1 break if ( b < 0 ) : b = ( - b ) t = ( a , b ) while b : ( a , b ) = ( b , ( a % b ) ) _gcdcache [ t ] = _gcdcache [ ( t [ 1 ] , t [ 0 ] ) ] = a while ( k < len ( args ) ) : ok = as_int ( args [ k ] ) k += 1 return a
computes nonnegative integer greatest common divisor .