#define _USE_MATH_DEFINES #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include using namespace std; using ll = long long; int N, A, B; ll mod = 998244353; int main() { cin >> N >> A >> B; vector kai(N+1, 0); kai[0] = 1; for(int i = 1; i <= N; ++i) { kai[i] = kai[i-1]*i; kai[i] %= mod; } ll ans = kai[N]-kai[N-1]*2+(A!=B ? kai[N-2] : 0); ans %= mod; ans = (ans+mod)%mod; cout << ans << endl; }