public class Algorithm {

    // test method
    private static void fizzBuzz() {
        for (int i = 0; i <= 100; i++) {
            if (i == 0)
                continue;
            if (i % 3 == 0 && i % 5 == 0)
                System.out.println("FIZZBUZZ");
            else if (i % 3 == 0)
                System.out.println("FIZZ");
            else if (i % 5 == 0)
                System.out.println("BUZZ");
            else
                System.out.println(i);
        }
    }

    /**
     * Returns the greatest common divisor of the specified value
     * @param a
     * @param b
     * @return
     */
    public static int euclidDivision(int a, int b) {
        int remain = a % b;
        if (remain == 0) {
            return b;
        }
        return euclidDivision(b, remain);
    }
}

@@ -661,24 +661,145 @@
 a, int b) %7B%0A
+        if (m == 0 %7C%7C m %3C n)%0A            throw new IllegalArgumentException();%0A        if (n == 0)%0A            return m;%0A
         int 
@@ -811,13 +811,13 @@
 n = 
-a %25 b
+m %25 n
 ;%0A  
@@ -838,18 +838,16 @@
 in == 0)
- %7B
 %0A       
@@ -862,15 +862,53 @@
 urn 
-b
+n
 ;%0A    
+    return euclidDivision(n, remain);%0A
     
@@ -917,44 +917,351 @@
     
+%0A
     
-return euclidDivision(b, remain)
+/**%0A     * Whether prime%0A     * @param n%0A     * @return%0A     */%0A    public boolean primalityTest(int n) %7B%0A        if (n %3C 2)%0A            return false;%0A        else if (n %25 2 == 0)%0A            return true;%0A        for (int i = 3; i %3C= n / i; i += 2) %7B%0A            if (n %25 i == 0)%0A                return false;%0A        %7D%0A        return true
 ;%0A  

Update MathUtil.java