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 CPP):

Solution:
#include <bits/stdc++.h>
using namespace std;
long long powmod(long long a, long long b) {
  long long res = 1;
  a %= 1000000007;
  for (; b; b >>= 1) {
    if (b & 1) res = res * a % 1000000007;
    a = a * a % 1000000007;
  }
  return res;
}
int tot, mou[2200], prime[2200], sum[2200];
bool notpri[2200];
void getmou() {
  mou[1] = 1;
  for (int i = 2; i < 2200; i++) {
    if (!notpri[i]) prime[++tot] = i, mou[i] = -1;
    for (int j = 1; j <= tot && prime[j] * i < 2200; j++) {
      notpri[i * prime[j]] = 1;
      if (i % prime[j] == 0) {
        mou[i * prime[j]] = 0;
        break;
      } else
        mou[i * prime[j]] = -mou[i];
    }
  }
  for (int i = 1; i < 2200; i++) sum[i] = sum[i - 1] + mou[i];
}
int g[2200][2200];
int gcd(int a, int b) {
  if (g[a][b]) return g[a][b];
  while (b) {
    int t = a % b;
    a = b;
    b = t;
  }
  return g[a][b] = a;
}
long long f(int d, int x) {
  long long res = 0;
  for (int i = 1; i <= d; i++) {
    if (gcd(i, x) == 1) res += (d / i);
  }
  return res;
}
void add(long long &a, long long b) {
  a += b;
  if (a >= (1 << 30)) a -= (1 << 30);
  if (a < 0) a += (1 << 30);
}
int main() {
  int a, b, c;
  cin >> a >> b >> c;
  if (b > c) swap(b, c);
  long long ans = 0;
  getmou();
  for (int i = 1; i <= a; i++) {
    for (int j = 1; j <= b; j++) {
      if (gcd(i, j) == 1) {
        add(ans, 1LL * (a / i) * mou[j] * f(b / j, i) % (1 << 30) *
                     f(c / j, i) % (1 << 30));
      }
    }
  }
  printf("%lld\n", ans);
  return 0;
}