code: static int gcd(int a, int b) {
  		while (a != b) {
  			if (a > b) {
  				int na = a % b;
  				if (na == 0) return b;
  				a = na;
  			} else {
  				int nb = b % a;
  				if (nb == 0) return a;
  				b = nb;
  			}
  		}
  		return a;
  	}
docs: duplicated here to avoid dependencies