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 ≤ 100).

Output

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

Examples

Input

2 2 2


Output

20


Input

5 6 7


Output

1520

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.
//package Round_146;

import java.util.*;
import java.io.*;

public class b {

	String input = "";
	String output = "";

	FastScanner in;
	PrintWriter out;

	
	
	
	void solve() throws Exception {
		int a = in.nextInt();
		int b = in.nextInt();
		int c = in.nextInt();
		HashMap<Integer, Long> hash = new HashMap<Integer, Long>();
		long sum = 0;
		long mod = 1073741824;
		for (int i=1; i<=a; i++)
			for (int j=1; j<=b; j++)
				for (int k=1; k<=c; k++)
					if (hash.containsKey(i*j*k)){
						sum = (sum + hash.get(i*j*k)) % mod; 
					}else {
						int d = i*j*k;
						long count = 0;
						for (int l=1; l*l<=d; l++){
							if (d % l ==0){
								count++;
								if (d/l != l) count++;
							}
						}
						hash.put(d, count);
						sum += count;
					}
		out.println(sum);
	}

	void run() {
		try {
			if (input.length() == 0) {
				InputStreamReader ins = new InputStreamReader(System.in);
				in = new FastScanner(new BufferedReader(ins));
			} else {
				FileReader f = new FileReader(input);
				in = new FastScanner(new BufferedReader(f));
			}
			if (output.length() == 0) {
				out = new PrintWriter(System.out);
			} else
				out = new PrintWriter(new File(output));

			solve();

			out.flush();
			out.close();
		} catch (Exception ex) {
			ex.printStackTrace();
			out.close();
		}
	}

	public static void main(String args[]) {
		new b().run();
	}

	class FastScanner {
		BufferedReader bf;
		StringTokenizer st;

		FastScanner(BufferedReader bf) {
			this.bf = bf;
		}

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

			return st.nextToken();
		}

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

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

		public double nextDouble() throws IOException {
			return Double.parseDouble(next());
		}

	}

}
