{"problem":{"name":"Snack","description":{"content":"For $D$ days, each day you choose exactly one of the following four actions: *   Pay $1$ yen and buy gum. *   Pay $3$ yen and buy candy. *   Pay $4$ yen and buy chocolate. *   Pay $6$ yen and buy whe","description_type":"Markdown"},"platform":"AtCoder","limit":{"time_limit":2000,"memory_limit":262144},"difficulty":"None","is_remote":true,"is_sync":true,"sync_url":null,"sign":"fps_24_a"},"statements":[{"statement_type":"Markdown","content":"For $D$ days, each day you choose exactly one of the following four actions:\n\n*   Pay $1$ yen and buy gum.\n*   Pay $3$ yen and buy candy.\n*   Pay $4$ yen and buy chocolate.\n*   Pay $6$ yen and buy wheat gluten snack.\n\nAfter $D$ days, you have paid a total of $N$ yen.  \nHow many possible sequences of $D$ days satisfy this condition? Output the answer modulo $998244353$.\nTwo sequences are considered different if there exists at least one day on which the purchased item is different.\n\n## Constraints\n\n*   $1 \\leq D \\leq 2 \\times 10^5$\n*   $1 \\leq N \\leq 10^6$\n*   $D, N$ are integers\n\n## Input\n\nThe input is given from standard input in the following format:\n\n$D$ $N$\n\n[samples]","is_translate":false,"language":"English"}],"meta":{"iden":"fps_24_a","tags":[],"sample_group":[["2 7","4\n\nThere are $4$ valid action sequences for $2$ days:\n\n*   On day $1$, pay $1$ yen for gum; on day $2$, pay $6$ yen for wheat gluten snack.\n*   On day $1$, pay $3$ yen for candy; on day $2$, pay $4$ yen for chocolate.\n*   On day $1$, pay $4$ yen for chocolate; on day $2$, pay $3$ yen for candy.\n*   On day $1$, pay $6$ yen for wheat gluten snack; on day $2$, pay $1$ yen for gum."],["200000 1000000","688682037"]],"created_at":"2026-03-03 11:01:14"}}