#include <cstdio>
#include <cstring>
#include <cstdlib>
#include <cassert>
#include <cctype>
#include <algorithm>
#include <functional>
#include <utility>
const int N = 1000000;
typedef long long ll;
const ll ha = 1000000007LL;
inline ll pow_mod(ll a, ll b) {
  ll ans = 1, res = a;
  while(b) {
    if(1LL & b) ans = ans * res % ha;
    res = res * res % ha; b >>= 1;
  }
  return ans;
}
inline ll inv(ll x) {
  return pow_mod(x, ha - 2LL);
}

ll fac[N + 5], ifac[N + 5];
inline void process() {
  fac[0] = 1;
  for(int i = 1; i <= N; i ++) fac[i] = fac[i - 1] * i % ha;
  ifac[N] = inv(fac[N]);
  for(int i = N - 1; i >= 0; i --) ifac[i] = ifac[i + 1] * (i + 1) % ha;
}
inline ll C(int n, int m) {
  if(n < m) return 0;
  return fac[n] * ifac[m] % ha * ifac[n - m] % ha;
}

ll f[N + 5]; int n, m, k;
inline void dp() {
  f[0] = 1;
  for(int i = 1; i <= m + k; i ++) {
    f[i] = f[i - 1] << 1;
    f[i] += ha - C(i - 1, m);
    f[i] += ha - C(i - 1, k);
    f[i] %= ha;
  }
}

int main() {
  process();
  scanf("%d%d%d", &n, &m, &k);
  dp();
  ll ans = 0;
  for(int i = n; i <= n + m + k; i ++) {
    ll val = f[i - n] * C(i - 1, n - 1) % ha;
    val *= pow_mod(3, n + m + k - i);
    ans = (ans + val) % ha;
  }
  printf("%lld\n", ans);
  return 0;
}