#include <bits/stdc++.h>
const int maxn = 3e5 + 1;
using namespace std;
const long long MOD = 1e9 + 7;
long long fac[maxn];
long long rev[maxn];
long long inv[maxn];
long long C(int n, int k) {
  if (n < k || k < 0) return 0;
  return fac[n] * inv[n - k] % MOD * inv[k] % MOD;
}
long long precalc() {
  fac[0] = 1;
  inv[0] = 1;
  rev[1] = 1;
  inv[1] = 1;
  fac[1] = 1;
  for (int i = 2; i < maxn; ++i) {
    fac[i] = fac[i - 1] * i % MOD;
    rev[i] = (MOD - MOD / i) * rev[MOD % i] % MOD;
    inv[i] = inv[i - 1] * rev[i] % MOD;
  }
}
long long pw(long long a, long long b) {
  long long res = 1;
  while (b) {
    if (b & 1) res = res * a % MOD;
    a = a * a % MOD;
    b >>= 1;
  }
  return res;
}
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  int n, m, k;
  cin >> n >> m >> k;
  precalc();
  long long ans = 0;
  for (int i = n; i <= n + m + k; ++i) {
    long long temp = 0;
    for (int c = 0; c <= min(i - n, k); ++c) {
      int ost = i - n - c;
      if (ost > m) continue;
      temp += C(i - 1, n - 1) * C(i - n, c) % MOD;
      if (temp >= MOD) temp -= MOD;
    }
    ans += temp * pw(3, n + m + k - i) % MOD;
    if (ans >= MOD) ans -= MOD;
  }
  cout << ans;
}
