Here is Prob. 27, Chap. 5, in the book Principles of Mathematical Analysis by Walter Rudin, 3rd edition:
Let $\phi$ be a real function defined on a rectangle $R$ in the plane, given by $a \leq x \leq b$, $\alpha \leq y \leq \beta$. A solution of the initial-value problem $$ y^\prime = \phi(x, y), \qquad y(a) = c \qquad (\alpha \leq c \leq \beta) $$ is, by definition, a differentiable function $f$ on $[a, b]$ such that $f(a) = c$, $\alpha \leq f(x) \leq \beta$, and $$ f^\prime(x) = \phi\left( x, f(x) \right) \qquad (a \leq x \leq b). $$ Prove that such a problem has at most one solution if there is a constant $A$ such that $$ \left| \phi \left(x, y_2 \right) - \phi \left(x, y_1 \right) \right| \leq A \left| y_2 - y_1 \right| $$ whenever $\left( x, y_1 \right) \in R$ and $\left( x, y_2 \right) \in R$.
Hint: Apply Exercise 26 to the difference of two solutions. Note that this uniqueness theorem does not hold for the initial-value problem $$ y^\prime = y^{1/2}, \qquad y(0) = 0, $$ which has two solutions: $f(x) = 0$ and $f(x) = x^2/4$. Find all other solutions.
Here is the link to my post here on Math SE on Prob. 26, Chap. 5, in Baby Rudin, 3rd edition:
My Effort:
Let $f_1$ and $f_2$ be any two solutions of the given initial-value problem, and let $g = f_1 - f_2$. Then as $f_1$ and $f_2$ are solutions to the given IVP, so $f_1$ and $f_2$ are differentiable functions on $[a, b]$ such that $f_1(a) = f_2(a) = c$; $\alpha \leq f_1(x) \leq \beta$ and $\alpha \leq f_2(x) \leq \beta$; and $$ f_1^\prime(x) = \phi \left( x, f_1(x) \right) \ \mbox{ and } \ f_2^\prime(x) = \phi \left( x, f_2(x) \right) $$ for all $x \in [a, b]$.
For all $x \in [a, b]$, since $\left( x, f_1(x) \right) \in R$ and $\left( x, f_2(x) \right) \in R$, therefore we can conclude that
$$ \left| g^\prime(x) \right| = \left| f_1^\prime(x) - f_2^\prime(x) \right| = \left| \phi \left( x, f_1(x) \right) - \phi \left( x, f_2(x) \right) \right| \leq A \left| f_1(x) - f_2(x) \right| = A \left| g(x) \right| $$ for all $x \in [a, b]$. Moreover, $$ g(a) = f_1(a) - f_2(a) = c - c = 0.$$ So, by the conclusion in Prob. 26, we have $g(x) = 0$ for all $x \in [a, b]$; that is, $f_1(x) = f_2(x)$ for all $x \in [a, b]$; that is, $f_1 = f_2$, and so the given initial-value problem has at most one solution.
Is this proof correct?
Now for the IVP $$ y^\prime = y^{1/2}, \qquad y(0) = 0. \tag{1}$$ Let $b$ be any real number such that $b > 0$.
If $f(x) = 0$ for all $x \in [0, b]$, then $$f^\prime(x) = 0 = \left( f(x) \right)^{1/2}, \ \mbox{ and } \ f(0) = 0.$$ Thus $f$ is a solution to the initial-value problem (1).
And, if $f(x) = x^2/4$ for all $x \in [0, b]$, then we have $$ f^\prime(x) = \frac{x}{2} = \left( \frac{x^2}{4} \right)^{1/2} = \left( f(x) \right)^{1/2}, \ \mbox{ and } \ f(0) = 0.$$ Thus this $f$ is also a solution to (1).
Now if $y \neq \hat{0}$, the zero function, then from (1) we obtain $$ \frac{1}{y^{1/2}} y^\prime = 1,$$ and so, upon integrating both sides, we get $$ 2 y^{1/2} = x + c, $$ where $c$ is an arbitrary constant of integration. Therefore, $$ y(x) = { (x+c)^2 \over 4 } \tag{2}$$ for all $x \in [0, b]$.
As $y(0) = 0$, so from (2) we obtain $$ c^2/4 = 0,$$ which implies that $c = 0$. So (2) becomes $$ y(x) = x^2/4$$ for all $x \in [0, b]$.
Thus, for any real number $b > 0$, the initial-value problem (2) has only the following two solutions: $f_1(x) = 0$ and $f_2(x) = x^2/4$ for all $x \in [0, b]$.
Is my reasoning correct? If so, then have I arrived at the correct conclusion as well?