If a game can result in a win, worth one point; a draw, worth half a point; or a loss, worth no points; how many ways are there of scoring
k points in
Applicable scenarios include NFL and chess.
- Input is via stdin, and consists of
kon separate lines.
nwill be a non-negative integer.
(n ≤ 16)
kwill be either a non-negative integer or a non-negative integer plus a half.
(k ≤ n)
- Output is to stdout. It may, but does not have to, include a trailing newline.
In each case, the first two lines are user-supplied input and the third line is the program output.
10 4.5 8350 16 8 5196627 16 13.5 13328 12 12 1