OFFSET
0,5
COMMENTS
This sequence was inspired by a puzzle, "IQ Tests," from the book Mathematical Puzzles and Curiosities.
Consider a multiple-choice question: "How many correct answer choices are there: (a) 1, (b) 1, (c) 2, (d) 2?" Answer 2 can be considered correct as it appears twice. This sequence counts the number of multiple-choice questions with a total n that contain a 'correct' answer.
REFERENCES
I. David, T. Khovanova, and Y. Shpilman, Mathematical Puzzles and Curiosities, World Scientific, 2026, p.5.
LINKS
Alois P. Heinz, Table of n, a(n) for n = 0..10000
FORMULA
EXAMPLE
Consider 5 partitions of 4: (1,1,1,1), (2,1,1), (2,2), (3,1), 4. Only partitions (2,2) and (3,1) satisfy the requirement. In the first case, value 2 appears twice; in the second case, value 1 appears once. Thus, a(5) = 2.
MAPLE
b:= proc(n, i) option remember; `if`(n=0, 1, `if`(i<1, 0,
add(`if`(i=j, 0, b(n-i*j, i-1)), j=0..n/i)))
end:
a:= n-> combinat[numbpart](n)-b(n$2):
seq(a(n), n=0..50); # Alois P. Heinz, Jan 29 2026
MATHEMATICA
Table[Total@ Map[Boole@ AnyTrue[Tally[#], SameQ @@ # &] &, IntegerPartitions[n]], {n, 0, 49}] (* Michael De Vlieger, Jan 29 2026 *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Tanya Khovanova and PRIMES STEP senior group, Jan 21 2026
STATUS
approved
