I have two polynomials $p$ and $q$ in $\mathbb R^n$. Is there a bound on the number of connected components of $\{x \in \mathbb R^n : p(x) = 0, q(x) \neq 0\}$ in terms of the degrees of $p$ and $q$?
(For example, if $n = 2$ and $\deg p = 1$, then number of connected components is at most $\deg q +1$, since $\{p = 0\}$ and $\{q = 0\}$ can intersect at most $\deg q$ times.)