{"problem":{"name":"Sum of Number of Divisors of Product","description":{"content":"An integer sequence of length between $1$ and $N$, inclusive, where each element is between $1$ and $M$, inclusive, is called a **good sequence**. The **score** of a good sequence is defined as the nu","description_type":"Markdown"},"platform":"AtCoder","limit":{"time_limit":3000,"memory_limit":262144},"difficulty":"None","is_remote":true,"is_sync":true,"sync_url":null,"sign":"arc182_c"},"statements":[{"statement_type":"Markdown","content":"An integer sequence of length between $1$ and $N$, inclusive, where each element is between $1$ and $M$, inclusive, is called a **good sequence**.\nThe **score** of a good sequence is defined as the number of positive divisors of $X$, where $X$ is the product of the elements in the sequence.\nThere are $\\displaystyle \\sum_{k=1}^{N}M^k$ good sequences. Find the sum of the scores of all those sequences modulo $998244353$.\n\n## Constraints\n\n*   $1 \\leq N \\leq 10^{18}$\n*   $1 \\leq M \\leq 16$\n*   All input values are integers.\n\n## Input\n\nThe input is given from Standard Input in the following format:\n\n$N$ $M$\n\n[samples]","is_translate":false,"language":"English"}],"meta":{"iden":"arc182_c","tags":[],"sample_group":[["1 7","16\n\nThere are seven good sequences: $(1),(2),(3),(4),(5),(6),(7)$. Their scores are $1,2,2,3,2,4,2$, respectively, so the answer is $1+2+2+3+2+4+2=16$."],["3 11","16095\n\nFor example, $(8,11)$ and $(1,8,2)$ are good sequences. Here is the process of calculating their scores:\n\n*   The product of the elements in $(8,11)$ is $8 \\times 11 = 88$. $88$ has eight positive divisors: $1,2,4,8,11,22,44,88$, so the score of $(8,11)$ is $8$.\n*   The product of the elements in $(1,8,2)$ is $1 \\times 8 \\times 2 = 16$. $16$ has five positive divisors: $1,2,4,8,16$, so the score of $(1,8,2)$ is $5$."],["81131 14","182955659\n\nRemember to take the result modulo $998244353$."]],"created_at":"2026-03-03 11:01:13"}}