Prove or disprove that there exists $K$ such that $|f(x)-f(y)|\leq K |x-y|,\;\forall\;\;x,y\in[0,1],$ edited version. Let $f$ be a function on $[0,1]$ into $\Bbb{R}$. Suppose that if $x\in[0,1],$ there exists $K_x$ such that \begin{align}|f(x)-f(y)|\leq K_x |x-y|,\;\;\forall\;\;y\in[0,1].\end{align}
Prove or disprove that there exists $K$ such that \begin{align}|f(x)-f(y)|\leq K |x-y|,\;\forall\;\;x,y\in[0,1].\end{align}
DISPROOF
Consider the function \begin{align} f:[0&,1]\to 
\Bbb{R},  \\&x\mapsto \sqrt{x} \end{align}
Let $x=0$ and $y\in (0,1]$ be fixed. Then,
\begin{align} \left| f(0)-f(y) \right|&=\left|0-\sqrt{y}  \right|   \end{align}
Take $y=1/(4n^2)$ for all $n.$ Then,
\begin{align} \left| f(0)-f\left(\dfrac{1}{4n^2}\right) \right|&=\left|0-\dfrac{1}{\sqrt{4n^2}}  \right| \\&=2n^{3/2}\left|\dfrac{1}{4n^2} -0 \right|   \end{align}
By assumption, there exists $K_0$ such that 
\begin{align} \left| f(0)-f\left(\dfrac{1}{4n^2}\right) \right|&=2n^{3/2}\left|\dfrac{1}{4n^2} -0 \right|\leq K_0\left|\dfrac{1}{4n^2} -0 \right|   \end{align}
Sending $n\to\infty,$ we have
\begin{align} \infty \leq K_0<\infty,\;\;\text{contradiction}.  \end{align}
Hence, the function $f$ is not Lipschitz in $[0,1]$.
QUESTION: Is my disproof correct?
 A: You are correct, the function $f$ is not Lipschitz in $[0,1]$, but your argument should be modified. You may simply say that
$$\frac{f(1/n)-f(0)}{\frac{1}{n}-0}=\sqrt{n}\to +\infty$$
which contradicts the fact that $|f(x)-f(y)|/|x-y|$ is bounded by a constant $K$.
On the other hand this is not a counterexample for your statement. For the same reason as above (Just take $y=1/n$), for $x=0$ there is no constant $K_0$ such that
$$|f(0)-f(y)|\leq K_0 |0-y|,\;\;\forall y\in[0,1].$$
Instead consider the function
$$f(x)=\cases{x\sin(1/x)& if $x\not=0$\\0& if $x=0$,}$$
If $x_n=1/(2\pi n)$ and $y_n=1/(2\pi n+\pi/2)$.
then  $|f(x_n)-f(y_n)|/|x_n-y_n|$ is unbounded which implies that $f$ is not Lipschitz in $[0,1]$, but for any $x\in[0,1],$ there exists $K_x$ such that $$|f(x)-f(y)|\leq K_x |x-y|,\;\;\forall\;\;y\in[0,1].$$
In fact take $K_0=1$ and for $x\in(0,1]$ the existence of $K_x$ follows from
$f'\in C^1((0,1])$. 
A: This isn't incorrect per se, but its unnecessarily convoluted.  To show that $f'$ is unbounded, just observe that $f'(x)=\frac{1}{2\sqrt{x}}$ so that $\lim_{x\to 0^+}f'(x)=\infty$.  Hence, $f$ is not Lipschitz on $[0,1]$, which is precisely what you want to prove.  That's all you need to say.
The last part is a little hand-wavy though.  Technically, you should say something like this:  $f$ is Lipschitz on $[\epsilon,1]$ with constant $K_\epsilon:=\sup_{\epsilon\leq x\leq 1}|f'(x)|$.  Since $K_\epsilon\to\infty$ as $\epsilon\to 0^+$, $f$ is not Lipschitz on $[0,1]$.
Better still just to do an explicit calculation, as the other fellow did.
