const MOD: usize = 1e9 as usize + 7; fn power(base: usize, times: usize) -> usize { if times == 0 { return 1usize; } if times == 1 { return base; } let temp = power(base, times/2); temp * temp % MOD * power(base, times%2) % MOD } fn fact_inv(size: usize) -> (Vec, Vec) { let mut facts = vec![0usize; size+1]; let mut fact_invs = vec![0usize; size+1]; let mut invs = vec![0usize; size+1]; facts[0] = 1; facts[1] = 1; fact_invs[0] = 1; fact_invs[1] = 1; invs[1] = 1; for i in 2..=size { facts[i] = facts[i-1] * i % MOD; invs[i] = MOD - invs[MOD % i] * (MOD / i) % MOD; fact_invs[i] = fact_invs[i - 1] * invs[i] % MOD; } (facts, fact_invs) } fn comb(n: usize, r: usize, facts: &Vec, fact_invs: &Vec) -> usize { facts[n] * fact_invs[r] % MOD * fact_invs[n-r] % MOD } fn main() { let mut abc = String::new(); std::io::stdin().read_line(&mut abc).ok(); let abc: Vec = abc.trim().split_whitespace().map(|s| s.parse().unwrap()).collect(); let a = abc[0]; let b = abc[1]; let c = abc[2]; let (facts, fact_invs) = fact_inv(300010); let mut result = 0usize; let mut p2s = vec![1usize; 300010]; for i in 1..300010 { p2s[i] = p2s[i-1] * 2 % MOD; } let summary = a+b+c; for acnt in 1..=a { let zval = (MOD + p2s[summary-acnt-1] - 1) % MOD; let patterns = comb(summary-acnt-1, b-1, &facts, &fact_invs) * comb(summary-acnt-b, c, &facts, &fact_invs) % MOD * c % MOD * power(summary-acnt-1, MOD-2) % MOD; result += patterns * zval % MOD; result %= MOD; } println!("{}", result); }