输入2个正整数m和n,求其最大公约数。
public static int getGreatestCommonDivisor(int m, int n) { int gcd = Math.min(m, n); while (!(m%gcd==0&&n%gcd==0)) { gcd++; }; return gcd; }