#include <bits/stdc++.h>
using namespace std;
using namespace std;
const int maxn = 2012;
bool isPrime(int a) {
  if (a <= 1) {
    return false;
  }
  for (int i = 2; i * i <= a; i++) {
    if (a % i == 0) {
      return false;
    }
  }
  return true;
}
struct Triple {
  int x, y, z;
  Triple() {}
  Triple(int x, int y, int z) : x(x), y(y), z(z) { sort(); }
  void sort() {
    if (x > y) {
      swap(x, y);
    }
    if (y > z) {
      swap(y, z);
    }
    if (x > y) {
      swap(x, y);
    }
  }
  bool operator<(const Triple &o) const {
    return x < o.x || x == o.x && (y < o.y || y == o.y && z < o.z);
  }
};
vector<int> primes;
map<Triple, unsigned> vmap[333];
int states = 0;
unsigned go(int dep, const Triple &triple) {
  if (dep == primes.size()) {
    return 1;
  }
  if ((vmap[dep]).find(triple) != vmap[dep].end()) {
    return (vmap[dep])[triple];
  }
  unsigned &ret = vmap[dep][triple] = 0;
  int p = primes[dep];
  for (int x = triple.x, i = 0; x; x /= p, i++) {
    for (int y = triple.y, j = 0; y; y /= p, j++) {
      for (int z = triple.z, k = 0; z; z /= p, k++) {
        ret += go(dep + 1, Triple(x, y, z)) * (i + j + k + 1);
      }
    }
  }
  return ret;
}
int main() {
  for (int i = 2; i < maxn; i++) {
    if (isPrime(i)) {
      primes.push_back(i);
    }
  }
  reverse(primes.begin(), primes.end());
  int a, b, c;
  scanf("%d%d%d", &a, &b, &c);
  unsigned res = go(0, Triple(a, b, c));
  res &= (1 << 30) - 1;
  printf("%d\n", (int)res);
}
