Problem: Let's denote d(n) as the number of divisors of a positive integer n. You are given three integers a, b and c. Your task is to calculate the following sum:

<image>

Find the sum modulo 1073741824 (230).

Input

The first line contains three space-separated integers a, b and c (1 ≤ a, b, c ≤ 2000).

Output

Print a single integer — the required sum modulo 1073741824 (230).

Examples

Input

2 2 2


Output

20


Input

4 4 4


Output

328


Input

10 10 10


Output

11536

Note

For the first example.

  * d(1·1·1) = d(1) = 1; 
  * d(1·1·2) = d(2) = 2; 
  * d(1·2·1) = d(2) = 2; 
  * d(1·2·2) = d(4) = 3; 
  * d(2·1·1) = d(2) = 2; 
  * d(2·1·2) = d(4) = 3; 
  * d(2·2·1) = d(4) = 3; 
  * d(2·2·2) = d(8) = 4. 



So the result is 1 + 2 + 2 + 3 + 2 + 3 + 3 + 4 = 20.

Solution (in JAVA):

Solution:
import java.io.*;
import java.util.*;

public class Main {
    static int n;

    static boolean[] isPrime;
    public static void sieve(){
        isPrime = new boolean[3000+1];
        Arrays.fill(isPrime, true); isPrime[1] = isPrime[0] = false;
        for (int i = 2; i*i <= n; i++) {
            if(isPrime[i]){
                for (int j = i * i; j <= n; j += i) {
                    isPrime[j] = false;
                }
            }
        }
    }

    static int[] spf;
    public static void spf(){
        spf = new int[3000+1];
        spf[1] = 1;
        for (int i = 2; i <= 3000; i++) {
            if(spf[i] == 0){
                spf[i] = i;
                for (int j = i * i; j <= 3000; j += i) {
                    if(spf[j] == 0) spf[j] = i;
                }
            }
        }
    }

    public static int getPrimeFactors(int x){

        HashSet<Integer> set = new HashSet<>();
        while(spf[x] != 1){
            set.add(spf[x]);
            x /= spf[x];
        }
        return set.size();
    }
    static int[] d;
    public static int numOfDivisors(int x){
        if(d[x] != 0) return d[x];
        int cnt = 0;
        for (int i = 1; i*i <= x; i++) {
            if(x%i == 0) {
                if(i*i != x) cnt += 2;
                else cnt++;
            }
        }
        return d[x] = cnt;
    }
    public static void main(String[] args) throws IOException, InterruptedException {
        d = new int[1000001];
        long sum = 0;
        int a = sc.nextInt(), b = sc.nextInt(), c = sc.nextInt();
        for (int i = 1; i <= a; i++) {
            for (int j = 1; j <= b; j++) {
                for (int k = 1; k <= c; k++) {
                    sum += numOfDivisors(i*j*k) % MOD;
                }
            }
        }
        pw.println(sum);
        pw.close();
    }

    public static void pairSort(Pair[] arr) {
        ArrayList<Pair> l = new ArrayList<>();
        Collections.addAll(l, arr);
        Collections.sort(l);
        for (int i = 0; i < arr.length; i++) {
            arr[i] = l.get(i);
        }
    }
    public static void longSort(long[] arr) {
        ArrayList<Long> l = new ArrayList<>();
        for (long i : arr) l.add(i);
        Collections.sort(l);
        for (int i = 0; i < arr.length; i++) {
            arr[i] = l.get(i);
        }
    }
    public static void intSort(int[] arr) {
        ArrayList<Integer> l = new ArrayList<>();
        for (int i : arr) l.add(i);
        Collections.sort(l);
        for (int i = 0; i < arr.length; i++) {
            arr[i] = l.get(i);
        }
    }

    static class Scanner {
        StringTokenizer st;
        BufferedReader br;

        public Scanner(InputStream s) {
            br = new BufferedReader(new InputStreamReader(s));
        }

        public String next() throws IOException {
            while (st == null || !st.hasMoreTokens())
                st = new StringTokenizer(br.readLine());
            return st.nextToken();
        }

        public int nextInt() throws IOException {
            return Integer.parseInt(next());
        }

        public long nextLong() throws IOException {
            return Long.parseLong(next());
        }

        public String nextLine() throws IOException {
            return br.readLine();
        }

        public double nextDouble() throws IOException {
            String x = next();
            StringBuilder sb = new StringBuilder("0");
            double res = 0, f = 1;
            boolean dec = false, neg = false;
            int start = 0;
            if (x.charAt(0) == '-') {
                neg = true;
                start++;
            }
            for (int i = start; i < x.length(); i++)
                if (x.charAt(i) == '.') {
                    res = Long.parseLong(sb.toString());
                    sb = new StringBuilder("0");
                    dec = true;
                } else {
                    sb.append(x.charAt(i));
                    if (dec)
                        f *= 10;
                }
            res += Long.parseLong(sb.toString()) / f;
            return res * (neg ? -1 : 1);
        }

        public boolean ready() throws IOException {
            return br.ready();
        }

        public int[] nextIntArr(int n) throws IOException {
            int[] arr = new int[n];
            for (int i = 0; i < n; i++) {
                arr[i] = Integer.parseInt(next());
            }
            return arr;
        }

        public long[] nextLongArr(int n) throws IOException {
            long[] arr = new long[n];
            for (int i = 0; i < n; i++) {
                arr[i] = Long.parseLong(next());
            }
            return arr;
        }

    }
    static class Pair implements Comparable<Pair>{
        int first; int second; int length;
        public Pair(int first, int second){
            this.first = first; this.second = second; this.length = second-first+1;
        }

        @Override
        public int compareTo(Pair p2) {
            if(first == p2.first) return second - p2.second;
            else return first - p2.first;
        }

        @Override
        public String toString() { return "("+ first + "," + second + ')'; }

    }
    static class Triple implements Comparable<Triple> {
        double x, y, z, sum;

        Triple(double a, double b, double c) { x = a; y = b; z = c; sum = x + y + z; }


        public int compareTo(Triple t)
        {
            if(Math.abs(sum - t.sum) < 1e-9) return x > t.x ? 1 : -1;
            return sum > t.sum ? 1 : -1;
        }
        public String toString()
        {
            return x + " " + y  + " " + z;
        }
    }

    static PrintWriter pw = new PrintWriter(System.out);
    static Scanner sc = new Scanner(System.in);
    static Random random = new Random();
    static final long MOD = 1073741824;
}