AtCoder Regular Contest 107
翻译中…
Problem Statement
翻译中…
You are given two positive integers $N$ and $K$. How many multisets of rational numbers satisfy all of the following conditions?
翻译中…
- The multiset has exactly
$N$elements and the sum of them is equal to$K$. - Each element of the multiset is one of
$1, \frac{1}{2}, \frac{1}{4}, \frac{1}{8}, \dots$. In other words, each element can be represented as$\frac{1}{2^i}\ (i = 0,1,\dots)$.
翻译中…
The answer may be large, so print it modulo $998244353$.
翻译中…
Constraints
翻译中…
$1 \leq K \leq N \leq 3000$- All values in input are integers.
翻译中…
Input
翻译中…
Input is given from Standard Input in the following format:
翻译中…
N K
翻译中…
Output
翻译中…
Print the number of multisets of rational numbers that satisfy all of the given conditions modulo $998244353$.
翻译中…
样例
Input #1
4 2
Output #1
2
The following two multisets satisfy all of the given conditions:
- ${1, \frac{1}{2}, \frac{1}{4}, \frac{1}{4}}$
- ${\frac{1}{2}, \frac{1}{2}, \frac{1}{2}, \frac{1}{2}}$
Input #2
2525 425
Output #2
687232272
题目信息
题面与样例版权归 AtCoder 及出题人所有;中文翻译由 AI 生成(CI 管线),如有出入请以原文为准。