#include <bits/stdc++.h>
using namespace std;
long long fac[300010], inv[300010], ivf[300010];
void initmo() {
  fac[0] = ivf[0] = inv[1] = 1;
  for (long long i = 1; i < 300010; i++) {
    if (i > 1)
      inv[i] =
          (1000000007 - 1000000007 / i * inv[1000000007 % i] % 1000000007) %
          1000000007;
    fac[i] = fac[i - 1] * i % 1000000007;
    ivf[i] = ivf[i - 1] * inv[i] % 1000000007;
  }
}
long long C(long long n, long long k) {
  return fac[n] * ivf[n - k] % 1000000007 * ivf[k] % 1000000007;
}
long long po(long long x, long long y) {
  long long res = 1;
  for (; y; y >>= 1) {
    if (y & 1) res = res * x % 1000000007;
    x = x * x % 1000000007;
  }
  return res;
}
int main() {
  initmo();
  long long a, b, c;
  cin >> a >> b >> c;
  if (a > 300010 || b > 300010 || c > 300010) return 0;
  a--;
  if (b > c) swap(b, c);
  long long ans = 0, sum = 1;
  for (long long k = a; k <= a + b + c; k++) {
    long long cur = po(3, a + b + c - k) * C(k, a) % 1000000007;
    cur = cur * sum % 1000000007;
    ans = (ans + cur) % 1000000007;
    long long s = k - a;
    sum = sum * 2 % 1000000007;
    if (b <= s) sum -= C(s, b);
    if (c <= s) sum -= C(s, s - c);
  }
  if (ans < 0) ans += 1000000007;
  cout << ans << endl;
  return 0;
}
