{{searchResults.length}} {{searchResults.length === 1 ? 'result' : 'results'}} for “{{searchWords}}”No results found for “{{searchWords}}”× back to contents
The condition says $Q(1),Q(2),Q(3),Q(4)\in\{1,2,3,4\}$. Four values come from a polynomial of degree at most $2$ exactly when the third difference vanishes: $Q(4)=Q(1)-3Q(2)+3Q(3)$.
With $d=Q(3)-Q(2)$ we need $Q(1)+3d\in\{1,\dots,4\}$: $d=0$ gives $4\cdot4=16$ choices, $d=1$ forces $Q(1)=1$ ($3$ choices), $d=-1$ forces $Q(1)=4$ ($3$ choices). That is $22$.
Removing the $4$ constants and the $2$ linear maps $x$, $5-x$ leaves $\boxed{16}$.