#include <bits/stdc++.h>
long long const maxn = 2000, lots = 1ll << 30ll;
long long squarefree[maxn + 2], gcd[maxn + 2][maxn + 2], factors[maxn + 2],
    factor[maxn + 2];
inline long long term(long long n, long long k) {
  long long res = 0;
  for (long long i = 1; i <= k; i++)
    if (gcd[n][i] == 1) res += k / i;
  return res;
}
int main() {
  for (long long i = 0; i <= maxn; i++)
    for (long long j = 0; j <= maxn; j++)
      gcd[i][j] = gcd[j][i] = (i ? gcd[j % i][i] : j);
  for (long long i = 2; i <= maxn; i++)
    if (not factor[i])
      for (long long j = (factor[i] = i, i * i); j <= maxn; j += i)
        if (not factor[j]) factor[j] = i;
  for (long long i = ++squarefree[1] + 1; i <= maxn; i++)
    factors[i] = factors[i / factor[i]] + 1,
    squarefree[i] =
        (squarefree[i / factor[i]] and (factor[i] != factor[i / factor[i]]));
  long long a, b, c, res = 0;
  std::cin >> a >> b >> c;
  for (long long i = 1; i <= 2000; i++)
    if (squarefree[i])
      for (long long j = 1; j <= a; j++)
        if (gcd[i][j] == 1)
          res += lots + (1 - 2u * (factors[i] & 1)) * (a / j) * term(j, b / i) *
                            term(j, c / i);
  std::cout << (res % lots) << std::endl;
}

### Prompt

Your task is to create a Cpp solution to the following 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.

### Response

```cpp
#include <bits/stdc++.h>
long long const maxn = 2000, lots = 1ll << 30ll;
long long squarefree[maxn + 2], gcd[maxn + 2][maxn + 2], factors[maxn + 2],
    factor[maxn + 2];
inline long long term(long long n, long long k) {
  long long res = 0;
  for (long long i = 1; i <= k; i++)
    if (gcd[n][i] == 1) res += k / i;
  return res;
}
int main() {
  for (long long i = 0; i <= maxn; i++)
    for (long long j = 0; j <= maxn; j++)
      gcd[i][j] = gcd[j][i] = (i ? gcd[j % i][i] : j);
  for (long long i = 2; i <= maxn; i++)
    if (not factor[i])
      for (long long j = (factor[i] = i, i * i); j <= maxn; j += i)
        if (not factor[j]) factor[j] = i;
  for (long long i = ++squarefree[1] + 1; i <= maxn; i++)
    factors[i] = factors[i / factor[i]] + 1,
    squarefree[i] =
        (squarefree[i / factor[i]] and (factor[i] != factor[i / factor[i]]));
  long long a, b, c, res = 0;
  std::cin >> a >> b >> c;
  for (long long i = 1; i <= 2000; i++)
    if (squarefree[i])
      for (long long j = 1; j <= a; j++)
        if (gcd[i][j] == 1)
          res += lots + (1 - 2u * (factors[i] & 1)) * (a / j) * term(j, b / i) *
                            term(j, c / i);
  std::cout << (res % lots) << std::endl;
}

```