#include #include using namespace std; const int N = 100005, mod = 998244353; int n, p, q, to[N << 1]; int pw[N << 1], bg[N << 1], cnt; int power(int a, int n) { int tp = 1; while (n) { if (n & 1) tp = 1ll * tp * a % mod; a = 1ll * a * a % mod, n >>= 1; } return tp; } int main() { ios::sync_with_stdio(0), cin.tie(0), cout.tie(0); cin >> n >> p >> q; for (int i = 1; i <= p; i++) to[i] = n + p - i + 1; for (int i = p + 1; i <= n; i++) to[i] = n + i; for (int i = 1; i <= n - q; i++) to[n + i] = i; for (int i = n - q + 1; i <= n; i++) to[n + i] = 2 * n - i - q + 1; for (int i = 1; i <= n; i++) { if (bg[i]) continue; int x = i, l = 1; bg[i] = ++cnt; while (!bg[to[x]]) { x = to[x]; bg[x] = cnt, l++; } for(int j = 2; j * j <= l; j++) if(l % j == 0){ int x = 0; while (l % j == 0) l /= j, x++; pw[j] = max(pw[j], x); } pw[l] = max(pw[l], 1); } int ans = 1; for (int i = 2; i <= 2 * n; i++) ans = 1ll * ans * power(i, pw[i]) % mod; if (p == 1 || q == 1) ans = 2; cout << ans << endl; }