MathDB
Putnam 2009 B3

Source:

December 7, 2009
Putnamfloor functionarithmetic sequencecollege contests

Problem Statement

Call a subset S S of {1,2,,n} \{1,2,\dots,n\} mediocre if it has the following property: Whenever a a and b b are elements of S S whose average is an integer, that average is also an element of S. S. Let A(n) A(n) be the number of mediocre subsets of {1,2,,n}. \{1,2,\dots,n\}. [For instance, every subset of {1,2,3} \{1,2,3\} except {1,3} \{1,3\} is mediocre, so A(3)\equal{}7.] Find all positive integers n n such that A(n\plus{}2)\minus{}2A(n\plus{}1)\plus{}A(n)\equal{}1.