#include <bits/stdc++.h>
using namespace std;
const int N = 9e5 + 5, MOD = 1e9 + 7;
int fac[N], rev[N];
int mpow(int x, int n) {
	int res = 1;
	while (n) {
		if (n & 1) res = 1LL * res * x % MOD;
		x = 1LL * x * x % MOD;
		n >>= 1;
	}
	return res;
}
int C(int n, int m) {
	return 1LL * fac[n] * rev[m] % MOD * rev[n - m] % MOD;
}
int main() {
	fac[0] = rev[0] = 1;
	for (int i = 1; i < N; ++ i) {
		fac[i] = 1LL * fac[i - 1] * i % MOD;
		rev[i] = mpow(fac[i], MOD - 2);
	}
	int n, m, k;
	scanf("%d%d%d", &n, &m, &k);
	int ans = 0, l = 0, r = 0, sum = 1;
	for (int s = 0; s <= m + k; ++ s) {
		int res = 1LL * C(s + n - 1, s) * mpow(3, m + k - s) % MOD;
		int L = max(0, s - k), R = min(m, s);
		while (l > L) (sum += C(s, -- l)) %= MOD;
		while (r < R) (sum += C(s, ++ r)) %= MOD;
		while (l < L) (sum += MOD - C(s, l ++)) %= MOD;
		while (r > R) (sum += MOD - C(s, r --)) %= MOD;
		(ans += 1LL * res * sum % MOD) %= MOD;
		sum = (2LL * sum + MOD - C(s, l) + MOD - C(s, r)) % MOD;
		l ++;
	}
	printf("%d\n", ans);
}
