public static int PGCD(int a, int b) { int temp = a%b; if (temp == 0) return b; return PGCD(b, temp); }