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 maxn = 2001;
int pri[maxn], mu[maxn], tot = 0;
bool isp[maxn];
int g[maxn][maxn];
inline int gcd(int a, int b) {
  if (a < b) swap(a, b);
  if (g[a][b]) return g[a][b];
  if (b == 0)
    return g[a][b] = a;
  else
    return g[a][b] = gcd(b, a % b);
}
inline void getpri() {
  mu[1] = 1;
  for (int i = 2; i < maxn; i++) {
    if (!isp[i]) {
      pri[tot++] = i;
      mu[i] = -1;
    }
    for (int j = 0; j < tot; j++) {
      if (i * pri[j] >= maxn) break;
      isp[i * pri[j]] = 1;
      if (i % pri[j] == 0) {
        mu[i * pri[j]] = 0;
        break;
      }
      mu[i * pri[j]] = -mu[i];
    }
  }
}
int main() {
  getpri();
  int ans = 0;
  int a, b, c;
  scanf("%d%d%d", &a, &b, &c);
  if (a > b) swap(a, b);
  if (a > c) swap(a, c);
  if (b < c) swap(b, c);
  for (int d = 1; d <= b; d++)
    if (mu[d] != 0)
      for (int i = 1; i <= a; i++)
        if (gcd(d, i) == 1) {
          int u = 0, v = 0;
          for (register int x = 1, y = d; y <= b; x++, y += d)
            if (gcd(x, i) == 1) u += b / y, v += c / y;
          ans += mu[d] * (a / i) * u * v;
        }
  printf("%d\n", ans & 0x3fffffff);
  return 0;
}