問題一覧 > 通常問題

No.1138 No Bingo!

レベル : / AI推定難易度 : 2200 / 実行時間制限 : 1ケース 3.000秒 / メモリ制限 : 512 MB / 標準ジャッジ問題
タグ : (AC するまで非表示) / 解いたユーザー数 28
作問者 : leafirby / テスター : WrongAccept
お気に入りにしたユーザー ProblemId : 4750 / 自分の提出
問題文最終更新日: 2020-07-26 23:40:02
This statement was translated by AI (claude-opus-5-5, effort medium) and may contain errors or differ in nuance from the original. The original statement takes precedence. Back to the original

Problem Statement

null has an $N\times N$ bingo card. You were told the following by null:

  • At this moment, exactly $N$ cells have not been punched.
  • At this moment, the card does not have a bingo.
Given this, find the number of possible states (patterns of punched holes) of null's bingo card.
Since the answer can be very large, output it modulo $998244353$.
Here, a bingo is a state in which all the cells on at least $1$ row, column, or diagonal of the bingo card are punched.

Input

$N$

$1\le N\le 2\times 10^5$
All inputs are integers.

Output

Output the answer modulo $998244353$, followed by a newline.

Sample

Sample 1
Input
5
Output
48

For example, the following state is possible. (Cells marked with x are punched.)

Sample 2
Input
15
Output
6638025

Output the answer modulo $998244353$.

Source (the problem statement has been partially revised.)

提出するには、Twitter 、GitHub、 Googleもしくは右上の雲マークをクリックしてアカウントを作成してください。