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;
const int N = 1e6;
const double eps = 1e-5;
const long long mod = 1LL << 30;
bitset<N + 5> isprim;
int prim[N], d;
int mu[N + 5], sum[N + 5];
void moblus() {
  isprim.reset();
  mu[1] = 1;
  d = 0;
  for (int i = 2; i <= N; i++) {
    if (!isprim[i]) prim[d++] = i, mu[i] = -1;
    for (int j = 0; j < d; j++) {
      if (i * prim[j] > N) break;
      isprim.set(i * prim[j]);
      if (i % prim[j] == 0) {
        mu[i * prim[j]] = 0;
        break;
      } else
        mu[i * prim[j]] = -mu[i];
    }
  }
  sum[0] = 0;
  for (int i = 1; i <= N; i++) sum[i] = sum[i - 1] + mu[i];
}
int gcd[2005][2005];
int nex[2005][2005];
int f[2005][2005];
long long Num(int n, int m) {
  if (!f[n][m])
    for (int i = 1; i <= m; i = nex[n][i]) f[n][m] += m / i;
  return f[n][m];
}
long long solve(int a, int b, int c, int n) {
  long long ans = 0;
  for (int i = 1; i <= n; i++)
    if (mu[i]) {
      long long cur = 0;
      for (int j = 1; j <= a; j = nex[i][j])
        cur += (a / j) * Num(j, b / i) * Num(j, c / i);
      ans += mu[i] * cur;
    }
  return ans % mod;
}
int main() {
  moblus();
  for (int i = 0; i <= 2000; i++) gcd[0][i] = gcd[i][0] = i;
  for (int i = 1; i <= 2000; i++) {
    int last = 1;
    for (int j = 1; j <= 2000; j++) {
      if (i < j)
        gcd[i][j] = gcd[i][j - i];
      else
        gcd[i][j] = gcd[i - j][j];
      if (j != 1 && gcd[i][j] == 1) nex[i][last] = j, last = j;
    }
    nex[i][last] = 2222;
  }
  int a, b, c;
  while (~scanf("%d%d%d", &a, &b, &c)) {
    printf("%I64d\n", solve(a, b, c, min(b, c)));
  }
  return 0;
}