Under construction

Still being built. Things may change

Gnutella Chessmaster

Time limit3sMemory limit512 MB

Summary
Count the non-attacking bishop placements on an n by n board for each bishop count k from 1 to 2n-1, modulo 998244353.
Level

Hard9 of 10

Topics
Combinatorics, Math, Divide and conquer, Dynamic programming
Solved
No attempts yet

Problem

Alexander has recently reached an absurdly high rating on the Chessforces competition website. His coach gave him a hard problem so that he could truly prove his skill.

Consider an n×nn \times n chessboard. A bishop is a chess piece that attacks all positions sharing a diagonal with it. A non-attacking configuration is an arrangement of several bishops on the chessboard in which no two bishops occupy the same position and no bishop attacks another.

Alexander has to count the number of non-attacking configurations with exactly kk bishops for each kk from 11 to 2n−12n - 1. The answers can be large, so each number is taken modulo 998 244 353998\,244\,353, a completely random number.

Input

The first line contains a single integer nn (1≤n≤1051 \leq n \leq 10^5).

Output

Print 2n−12n - 1 integers. The kk-th integer is the number of non-attacking configurations of exactly kk bishops on an n×nn \times n chessboard, modulo 998 244 353998\,244\,353.

Examples3

  1. Example 1

    Input
    2
    
    Expected output
    4 4 0
    
  2. Example 2

    Input
    3
    
    Expected output
    9 26 26 8 0
    
  3. Example 3

    Input
    10
    
    Expected output
    100 4380 110960 1809464 20014112 154215760 837543200 214861037 625796024 941559921 770927213 837612209 756883449 146369278 295974400 17275136 246784 1024 0