4 1 2 3 5
1
2
6
5
* When $k=1$: For $i=1$, the bitwise $\mathrm{OR}$ operation of $A_i$ and $A_k$ is $1$. Therefore, the answer for the case $k=1$ is $A_1=1$.
* When $k=2$: For $i=1,2$, the bitwise $\mathrm{OR}$ operation of $A_i$ and $A_k$ is $3,2$, respectively. Therefore, the answer for the case $k=2$ is $A_2=2$.
* When $k=3$: For $i=1,2,3$, the bitwise $\mathrm{OR}$ operation of $A_i$ and $A_k$ is all $3$. Therefore, the answer for the case $k=3$ is $A_1\times A_2\times A_3=6$.
* When $k=4$: For $i=1,2,3,4$, the bitwise $\mathrm{OR}$ operation of $A_i$ and $A_k$ is $5,7,7,5$, respectively. Therefore, the answer for the case $k=4$ is $A_1\times A_4=5$.9 3 1 4 1 5 9 2 6 5
3 1 4 1 20 9 2 48 100
12 437926 528156 284664 1038330 692060 720863 602077 1027766 868190 532252 982711 876446
437926 528156 284664 94842632 158208162 985930968 548875758 875494466 345599613 605424119 111381243 768586512
{
"problem": {
"name": "Subset Product Problem",
"description": {
"content": "You are given a length-$N$ sequence of non-negative integers $A=(A_1,A_2,\\ldots,A_N)$. For $k=1,2,\\ldots,N$, solve the following problem. * Find the **product**, modulo $998244353$, of $A_i$ for al",
"description_type": "Markdown"
},
"platform": "AtCoder",
"limit": {
"time_limit": 6000,
"memory_limit": 262144
},
"difficulty": "None",
"is_remote": true,
"is_sync": true,
"sync_url": null,
"sign": "arc205_e"
},
"statements": [
{
"statement_type": "Markdown",
"content": "You are given a length-$N$ sequence of non-negative integers $A=(A_1,A_2,\\ldots,A_N)$.\nFor $k=1,2,\\ldots,N$, solve the following problem.\n\n* Find the **product**, modulo $998244353$, of $A_i$ for al...",
"is_translate": false,
"language": "English"
}
]
}