We will say that a point of the plane $(u, v)$ lies between the parabolas $y = f(x)$ and $y = g(x)$ if $f(u) \leq v \leq g(u)$. Find the smallest real $p$ for which the following statement is true: for any segment, the ends and the midpoint of which lie between the parabolas $y = x^2$ and $y=x^2+1$, then they lie entirely between the parabolas $y=x^2$ and $y=x^2+p$.