Problem

Source: Tournament of Towns 2016 Fall Tour, A Senior, Problem #6

Tags: algebra, polynomial, number theory, Game Theory, combinatorics, Combinatorial games



Petya and Vasya play the following game. Petya conceives a polynomial $P(x)$ having integer coefficients. On each move, Vasya pays him a ruble, and calls an integer $a$ of his choice, which has not yet been called by him. Petya has to reply with the number of distinct integer solutions of the equation $P(x)=a$. The game continues until Petya is forced to repeat an answer. What minimal amount of rubles must Vasya pay in order to win? (Anant Mudgal) (Translated from here.)