Problem

Source:

Tags: algebra, polynomial, modular arithmetic, number theory proposed, number theory



For integers $a$ and $b$ with $0 \leq a,b < {2010}^{18}$ let $S$ be the set of all polynomials in the form of $P(x)=ax^2+bx.$ For a polynomial $P$ in $S,$ if for all integers n with $0 \leq n <{2010}^{18}$ there exists a polynomial $Q$ in $S$ satisfying $Q(P(n)) \equiv n \pmod {2010^{18}},$ then we call $P$ as a good polynomial. Find the number of good polynomials.