#include #include using namespace atcoder; using mint=modint998244353; using namespace std; using ll=long long; using ull=unsigned long long; #define rep(i,a,b) for(ll i=(ll)(a);i<(ll)(b);i++) #define rrep(i,a,b) for(ll i=(ll)(a-1);i>=(ll)(b);i--) #define MOD 998244353 //#define MOD 1000000007 #define INF 1e18 #define Pair pair //#define PI numbers::pi //#define E numbers::e template bool chmax(T& a,T b){if(a bool chmin(T& a,T b){if(a>b){a=b;return 1;}return 0;} ll dx[8]={-2,-1,1,2,-2,-1,1,2}; ll dy[8]={-1,-2,-2,-1,1,2,2,1}; int main(){ int H,W,Q; cin >> H >> W >> Q; vector nCr(H+W+1,0); nCr[0]=1; for(int i=1;i> t; mint ans; if(t*(H+t-W)>0){ if(0