#include <bits/stdc++.h>
using namespace std;
const int inf = (int)1e9 + 7;
const int mod = (int)1e9 + 7;
const long long linf = (long long)1e18 + 7;
vector<int> fact;
int powm(int n, int p) {
  int res = 1;
  while (p > 0) {
    if (p & 1) res = (res * 1ll * n) % mod;
    p >>= 1;
    n = (n * 1ll * n) % mod;
  }
  return res;
}
int inv(int n) { return powm(n, mod - 2); }
int binom(int n, int k) {
  return (fact[n] * 1ll * inv((fact[k] * 1ll * fact[n - k]) % mod)) % mod;
}
void solve() {
  fact.resize(1e6);
  fact[0] = 1;
  for (int i = (1); i <= (1e6); i++) {
    fact[i] = (fact[i - 1] * 1ll * i) % mod;
  }
  int n, m, k;
  cin >> n >> m >> k;
  int l = n + m + k;
  int res = 0;
  for (int i = (n); i <= (l); i++) {
    int sum = 0;
    for (int j = (max(0, i - n - k)); j <= (min(i - n, m)); j++) {
      sum += binom(i - n, j);
      sum %= mod;
    }
    int temp = (sum * 1ll * binom(i - 1, n - 1)) % mod;
    res += (temp * 1ll * powm(3, l - i)) % mod;
    res %= mod;
  }
  cout << res;
}
int main() {
  ios::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  if (0) freopen(".in", "r", stdin);
  solve();
  return 0;
}
