#include <bits/stdc++.h>
int size, a, b, c, op;
int pri[2050], prime[305], sa[2020], sb[2020], sc[2020];
long long dpa[2020], dpb[8000200], ss[2020], ll[10];
bool in[2020];
void start() {
  int i, j, k, x, y, z;
  for (i = 2; i <= 50; i++) {
    for (j = 2 * i; j <= 2000; j += i) {
      in[j] = 1;
    }
  }
  size = 0;
  for (i = 2; i <= 2000; i++) {
    if (!in[i]) {
      size++;
      prime[size] = i;
    }
  }
  std::fill(pri, pri + 2011, 0);
  pri[1] = 1;
  for (i = 1; i <= size; i++) {
    for (j = prime[i]; j <= 2000; j += prime[i]) {
      if (pri[j] == 0) pri[j] = prime[i];
    }
  }
  for (i = 2; i <= 2000; i++) {
    x = i;
    while (x % pri[i] == 0) x /= pri[i];
    pri[i] *= pri[x];
  }
  for (i = 1; i <= 2000; i++) {
    sa[i] = a / i;
    sb[i] = b / i;
    sc[i] = c / i;
  }
  std::fill(dpa, dpa + 2020, -1);
  std::fill(dpb, dpb + 8000000, -1);
  for (j = 1; j <= c; j++) {
    for (i = 1; i <= c; i++) {
      if (i % j == 0) {
        ss[j] += sc[i];
        ss[j] %= 1073741824;
      }
    }
  }
}
int gcd(int aa, int bb) {
  while (aa * bb != 0) {
    if (aa > bb)
      aa = aa - bb;
    else
      bb = bb - aa;
  }
  if (aa == 0)
    return bb;
  else
    return aa;
}
void create_dpb(int bb);
void dfs(int y, int aa, long long value);
void create_dpa(int aa) {
  int i, j, k, x, y;
  long long ans = 0;
  for (j = 1; j <= aa; j++) {
    if (gcd(aa, j) == 1) {
      for (i = j; i <= b; i += aa) {
        y = aa * pri[i];
        if (dpb[y] == -1) create_dpb(y);
        ans += dpb[y] * sb[i];
        ans %= 1073741824;
      }
    }
  }
  dpa[aa] = ans;
}
void create_dpb(int aa) {
  int i, j = aa, k, x, y = 0;
  long long ans = 0;
  for (i = 1; i <= size; i++) {
    if (aa % prime[i] == 0) {
      y++;
      x = prime[i];
      ll[y] = prime[i];
      aa /= prime[i];
    }
    if (prime[i] > aa) break;
  }
  op = 0;
  dfs(y, 1, 1);
  dpb[j] = op;
}
void dfs(int y, int aa, long long value) {
  if (aa == y + 1) {
    int sgn;
    if (value > 0)
      sgn = 1;
    else {
      sgn = -1;
      value = -value;
    }
    if (value <= c) {
      op += ss[value] * sgn;
      op %= 1073741824;
    }
    return;
  }
  dfs(y, aa + 1, value);
  dfs(y, aa + 1, value * ll[aa] * (-1));
}
int main() {
  int i, j, k, x, y, z;
  long long ans = 0;
  scanf("%d%d%d", &a, &b, &c);
  start();
  for (i = 1; i <= a; i++) {
    x = pri[i];
    if (dpa[x] == -1) create_dpa(x);
    ans += dpa[x] * sa[i];
    ans %= 1073741824;
  }
  printf("%I64d", ans);
  getchar();
  getchar();
}
