Define $I_Q$ to be all the closed intervals in $\mathbb{R}$ with rational endpoints. Fix a positive integer $n \in \mathbb{Z}^+$, for any $I_1, I_2,...,I_n$ in $I_Q$, pairwise disjoint, we can define $$E_{I_1,I_2...,I_n} = \{x\in \mathbb{R}|\exists y_1\in I_1,...y_n \in I_n, st. F(x,y_1) = F(x,y_2) =... =F(x,y_n) = 0\}$$Hence, $E_{I_1,I_2...,I_n} \subset \{p(x)\ge n\}$. Since for n arbitrary real numbers, they can always be covered in n pairwise disjoint intervals respectively in $I_Q$, it is easy to prove that $\bigcup_{I_1,...,I_n\in I_Q, pairwise\ dijoint}E_{I_1,...I_n} = \{p(x)\ge n\}$. Since this is a countable union, we only need to prove that $E_{I_1,I_2...,I_n}$ is an open or a closed set.
In fact, $E_{I_1,I_2...,I_n}$ is a closed set. Foy any limit point of $E_{I_1,I_2...,I_n}$, denoted by $x_0$, there is a sequence $\{x_m\}$ in $E_{I_1,I_2...,I_n}$ which converges to $x_0$. Meanwhile, by definition, there are sequences $\{y_m^{(1)}\},...,\{y_m^{(n)}\}$ such that $F(x_m,y_m^{(1)}) =...= F(x_m, y_m^{(n)}) = 0$. Since these are all bounded sequences, we can easily take n convergent subsequences one after another, so just assume that they are all convergent and denote their limits by $y_1,...y_n$. Since $F$ is continuous, we must have $F(x_0,y_1) = ... =F(x_0, y_n) = 0$. Hence, $x_0 \in E_{I_1,I_2...,I_n}$. Finishing the proof.