This problem consists of two parts, but I cannot tell the difference between them.
Show that $f(x,y)=xy^2$
(a) satisfies a Lipschitz condition on any rectangle $a \le x \le b$ and $c \le y \le d$;
(b) does not satisfy a Lipschitz condition on any strip $a \le x \le b$ and $-\infty \lt y \lt \infty$.
I tried using the definition that the book gives: that is, to show that $f(x,y)$ satisfies a Lipschitz condition, then we need to show that
$\frac{f(x,y_1)-f(x,y_2)}{y_1-y_2}$ is bounded on the given region.
$\frac{f(x,y_1)-f(x,y_2)}{y_1-y_2}=\frac{xy_1^2-xy_2^2}{y_1-y_2}=x(y_1+y_2)$.
Thus, if $x$ is bounded and $y$ is bounded, then $\frac{f(x,y_1)-f(x,y_2)}{y_1-y_2}$ is bounded.
The confusion is that for part (b), since we are considering $y$ that is strictly greater than $-\infty$ and strictly less than $\infty$ then $y$ is bounded, so I'm getting that $f(x,y)$ satisfies a Lipschitz condition for both (a) and (b).
Is there something I am not seeing?
Hint: Let's say, for the sake of simplicity, that $a=-1,\ b=2$ and your Lipschitz constant for $[-1,2]\times\Bbb R$ is $L$. Then $$\lvert f(1,0)-f(1,2L)\rvert=4L^2>L\lVert (1,0)-(1,2L)\rVert$$
A couple of issues with what you did:
In your calculation of $$\left\lvert\dfrac{f(x,y_1)-f(x,y_2)}{y_1-y_2}\right\rvert=\lvert x(y_1+y_2)\rvert$$ you wanted the RHS to be bounded, because you are already dividing by the norm of the difference. This is not the case if $y_1,y_2\in\Bbb R$ arbitrarily.
Regardless, you need not evaluate just $f(x,y_1)-f(x,y_2)$, but you have to confront $f(x_1,y_1)-f(x_2,y_2)$ with $\lVert (x_1-x_2,y_1-y_2)\rVert$ as $(x_1,y_1)$ and $(x_2,y_2)$ range on the whole domain of interest. Evaluating at fixed $x$ is not enough (a priori).