Derivative of $f(x)$ at $0$, when $\lim_{x \to 0} f(x)/|x|=1$ I need to prove, or give a counter example:

If $\lim_{x \to 0} \dfrac{f(x)}{|x|} = 1$, then $f$ is not differentiable at 0.

I think it's true but can't formalize a proof (I tried proving it straight from the definition of the derivative.
Thanks. 
 A: The way to think about this problem is that the condition you give means $f(x)$ looks $|x|$ (plus higher order terms) near $x = 0$.  And since $|x|$ is not differentiable at $x = 0$, neither is $f(x)$.
To be more precise about it, use the fact that the limit is defined and this means that the two directional derivatives --- from the left and from the right --- must exist and are equal.
First consider the left limit, $x \leq 0$.
$$
\lim_{x \nearrow 0} \frac{f(x)}{|x|} = \lim_{x \nearrow 0} \frac{f(x)}{-x} = -\lim_{x \nearrow 0} \frac{f(x)}{x} = 1 \Rightarrow \lim_{x \nearrow 0} \frac{f(x)}{x} = -1\,.
$$
Now consider the right limit, $x \geq 0$.
$$
\lim_{x \searrow 0} \frac{f(x)}{|x|} = \lim_{x \searrow 0} \frac{f(x)}{x} = 1 \Rightarrow \lim_{x \searrow 0} \frac{f(x)}{x} = 1\,.
$$
Now consider the definition of the derivative of $f$ at $x$.
$$
\frac{df}{dx}\!(0) = \lim_{h \rightarrow 0} \frac{f(0+h)-f(0)}{h}\,.
$$ 
This limit does not exist, because the two above directional limits disagree.  Hence, $f$ is not differentiable at $0$.
A: Note that
$$\lim\limits_{h\rightarrow 0}f(h)= \lim\limits_{ h\rightarrow 0}|h|\cdot \lim\limits_{h\rightarrow0 }{f(h)\over |h|}=0\cdot1=0.$$
Assuming $f$ is continuous at $0$, we have $f(0)=0$.
Then:
$$\lim\limits_{h\rightarrow0^+}{f(h)\over h}=\lim\limits_{h\rightarrow0^+}{f(h)\over |h|}=1,$$
while
$$\lim\limits_{h\rightarrow0^-}{f(h)\over h}=-\lim\limits_{h\rightarrow0^-}{f(h)\over -h}
=-\lim\limits_{h\rightarrow0^-}{ f(h)\over |h|}=-1;$$
whence $f'(0)=\lim\limits_{h\rightarrow0}{f(h)\over h}$ does not exist.
If $f$ is not continuous at 0, then of course $f$ is not differentiable at 0.
