{"problem":{"name":"16 Integers","description":{"content":"You are given $16$ non-negative integers $X_{i, j, k, l}$ $(i, j, k, l \\in \\lbrace 0, 1 \\rbrace)$ in ascending order of $(i, j, k, l)$.   Let $N = \\displaystyle \\sum_{i=0}^1 \\sum_{j=0}^1 \\sum_{k=0}^1 ","description_type":"Markdown"},"platform":"AtCoder","limit":{"time_limit":2000,"memory_limit":262144},"difficulty":"None","is_remote":true,"is_sync":true,"sync_url":null,"sign":"abc336_g"},"statements":[{"statement_type":"Markdown","content":"You are given $16$ non-negative integers $X_{i, j, k, l}$ $(i, j, k, l \\in \\lbrace 0, 1 \\rbrace)$ in ascending order of $(i, j, k, l)$.  \nLet $N = \\displaystyle \\sum_{i=0}^1 \\sum_{j=0}^1 \\sum_{k=0}^1 \\sum_{l=0}^1 X_{i,j,k,l}$.  \nFind the number, modulo $998244353$, of sequences $(A_1, A_2, ..., A_{N+3})$ of length $N + 3$ consisting of $0$s and $1$s that satisfy the following condition.\n\n*   For every quadruple of integers $(i, j, k, l)$ $(i, j, k, l \\in \\lbrace 0, 1 \\rbrace)$, there are exactly $X_{i,j,k,l}$ integers $s$ between $1$ and $N$, inclusive, that satisfy:\n    *   $A_s = i$, $A_{s + 1} = j$, $A_{s + 2} = k$, and $A_{s + 3} = l$.\n\n## Constraints\n\n*   $X_{i, j, k, l}$ are all non-negative integers.\n*   $1 \\leq \\displaystyle \\sum_{i=0}^1 \\sum_{j=0}^1 \\sum_{k=0}^1 \\sum_{l=0}^1 X_{i,j,k,l} \\leq 10^6$\n\n## Input\n\nThe input is given from Standard Input in the following format:\n\n$X_{0,0,0,0}$ $X_{0,0,0,1}$ $X_{0,0,1,0}$ $X_{0,0,1,1}$ $X_{0,1,0,0}$ $X_{0,1,0,1}$ $X_{0,1,1,0}$ $X_{0,1,1,1}$ $X_{1,0,0,0}$ $X_{1,0,0,1}$ $X_{1,0,1,0}$ $X_{1,0,1,1}$ $X_{1,1,0,0}$ $X_{1,1,0,1}$ $X_{1,1,1,0}$ $X_{1,1,1,1}$\n\n[samples]","is_translate":false,"language":"English"}],"meta":{"iden":"abc336_g","tags":[],"sample_group":[["0 0 0 0 0 0 0 0 0 0 1 0 0 1 0 0","1\n\nThis input corresponds to the case where $X_{1, 0, 1, 0}$ and $X_{1, 1, 0, 1}$ are $1$ and all others are $0$.  \nIn this case, only one sequence satisfies the condition, which is $(1, 1, 0, 1, 0)$."],["1 1 2 0 1 2 1 1 1 1 1 2 1 0 1 0","16"],["21 3 3 0 3 0 0 0 4 0 0 0 0 0 0 0","2024"],["62 67 59 58 58 69 57 66 67 50 68 65 59 64 67 61","741536606"]],"created_at":"2026-03-03 11:01:14"}}