#include #define rep(i,a,b) for(int i=a;i= mod ? x - mod : x; } template int add(int x, T... y) { return add(x, add(y...)); } int mul(int x, int y) { return 1LL * x * y % mod; } template int mul(int x, T... y) { return mul(x, mul(y...)); } int sub(int x, int y) { return add(x, mod - y); } int modpow(int a, long long b) { int ret = 1; while (b > 0) { if (b & 1) ret = 1LL * ret * a % mod; a = 1LL * a * a % mod; b >>= 1; } return ret; } int modinv(int a) { return modpow(a, mod - 2); } /*---------------------------------------------------------------------------------------------------             ∧_∧       ∧_∧  (´<_` )  Welcome to My Coding Space!      ( ´_ゝ`) /  ⌒i     /   \    | |     /   / ̄ ̄ ̄ ̄/  |   __(__ニつ/  _/ .| .|____      \/____/ (u ⊃ ---------------------------------------------------------------------------------------------------*/ int memo[201][201]; int f(int a, int b) { assert(0 < a); assert(0 < b); if (a == 1 || b == 1) return 1; if (0 <= memo[a][b]) return memo[a][b]; return memo[a][b] = add(f(a, b - 1), f(a - 1, b)); } //--------------------------------------------------------------------------------------------------- void _main() { rep(a, 0, 201) rep(b, 0, 201) memo[a][b] = -1; int Q; cin >> Q; rep(q, 0, Q) { int a, b, c; cin >> a >> b >> c; int ans = 0; ans = add(ans, f(a, b + c + 1)); ans = add(ans, f(b, a + c + 1)); ans = add(ans, f(c, a + b + 1)); rep(aa, 0, a) rep(bb, 0, b) rep(cc, 0, c) { int d = mul(f(aa + 1, bb + 1), f(a - aa, cc + 1), f(b - bb, c - cc)); ans = add(ans, d); } printf("%d\n", ans); } }