#include <bits/stdc++.h>
using namespace std;

typedef long long ll;
typedef unsigned long long ull;
typedef pair<ll, ll> P;

#define fi first
#define se second
#define repl(i,a,b) for(ll i=(ll)(a);i<(ll)(b);i++)
#define rep(i,n) repl(i,0,n)
#define all(x) (x).begin(),(x).end()
#define dbg(x) cout<<#x"="<<x<<endl
#define mmax(x,y) (x>y?x:y)
#define mmin(x,y) (x<y?x:y)
#define maxch(x,y) x=mmax(x,y)
#define minch(x,y) x=mmin(x,y)
#define uni(x) x.erase(unique(all(x)),x.end())
#define exist(x,y) (find(all(x),y)!=x.end())
#define bcnt __builtin_popcountll

#define INF 1e16
#define mod 1000000007

ll N,M,K;
ll fac[1000010],finv[1000010];

ll mod_pow(ll a,ll n){
  ll res=1;
  while(n>0){
    if(n&1)res=res*a%mod;
    a=a*a%mod;
    n>>=1;
  }
  return res;
}
ll comb(ll n,ll r){
  if(n<0||r<0||n<r)return 0;
  return (fac[n]*finv[r]%mod)*finv[n-r]%mod;
}

int main(){
  cin.tie(0);
  ios::sync_with_stdio(false);
  fac[0]=1;
  rep(i,1000001)fac[i+1]=fac[i]*(i+1)%mod;
  rep(i,1000001)finv[i]=mod_pow(fac[i],mod-2);

  cin>>N>>M>>K;
  
  ll res=0;
  ll k3=1;
  repl(i,N,N+M+K+1){
    ll R=i-N;
    ll k1=comb(i-1,N-1);
    ll k2=mod_pow(3,N+M+K-i);
    (res+=(k1*k2%mod)*k3%mod)%=mod;
    k3=(k3+k3)%mod;
    if(R>=K){
      k3=(k3-comb(R,R-K)+mod)%mod;
    }
    if(R>=M){
      k3=(k3-comb(R,M)+mod)%mod;
    }
  }
  cout<<res<<endl;

  return 0;
}
