#include <bits/stdc++.h>
using namespace std;
const int mod = 1000000007;
long long mpow(long long x, long long n) {
  long long res = 1;
  while (n) {
    if (n & 1) res = res * x % mod;
    x = x * x % mod;
    n /= 2;
  }
  return res;
}
vector<long long> fac(1000000, 1);
vector<long long> invfac(fac.size(), 1);
long long bin(int k, int n) {
  if (k < 0 || k > n) return 0;
  return fac[n] * invfac[k] % mod * invfac[n - k] % mod;
}
int main() {
  for (int i = 2; i < fac.size(); ++i) fac[i] = fac[i - 1] * i % mod;
  invfac.back() = mpow(fac.back(), mod - 2);
  for (int i = fac.size() - 2; i > 0; --i)
    invfac[i] = invfac[i + 1] * (i + 1) % mod;
  int n, m, k;
  while (cin >> n >> m >> k) {
    long long sum = 0, res = 0;
    for (int s = 0; s <= m + k; ++s) {
      long long mul = mpow(3, m + k - s) * bin(s, s + n - 1) % mod;
      sum = 0;
      for (int i = max(0, s - k); i <= min(s, m); ++i) {
        sum = (sum + bin(i, s)) % mod;
      }
      res = (res + mul * sum) % mod;
    }
    cout << res << endl;
  }
  return 0;
}
