#include <bits/stdc++.h>
using namespace std;
int a, b, c, g[2020][2020];
long long ans;
int gcd(int a, int b) { return b ? gcd(b, a % b) : a; }
int mu(int n) {
  int ret = 1;
  for (int x = 2; x * x <= n; ++x)
    if (n % x == 0) {
      ret = -ret;
      n /= x;
      if (n % x == 0) return 0;
    }
  if (n > 1) ret = -ret;
  return ret;
}
int F(int x, int n) {
  int ret = 0;
  for (int i = 1; i <= n; ++i)
    if (g[i][x] == 1) ret += n / i;
  return ret;
}
int main() {
  scanf("%d %d %d", &a, &b, &c);
  for (int x = 0; x <= 2000; ++x)
    for (int y = 0; y <= 2000; ++y) {
      g[x][y] = gcd(x, y);
    }
  for (int d = 1; d <= b && d <= c; ++d)
    if (mu(d) != 0) {
      for (int i = 1; i <= a; ++i)
        if (g[i][d] == 1) {
          ans += mu(d) * (a / i) * F(i, b / d) * F(i, c / d);
        }
    }
  printf("%d\n", ans % (1 << 30));
}
