If $f$ is uniformly continuous and integrable, then $\lim_{x\to \infty }f(x)=0$. Let $f$ an integrable function (i.e. $L^1(\mathbb R)$). Suppose $f$ is uniformly continuous. Prove that $$\lim_{|x|\to \infty }f(x)=0.$$
If suppose first that $\ell:=\lim_{|x|\to \infty }f(x)$ exist. By contradiction, I suppose $\ell\neq 0$, and suppose WLOG that $\ell>0$. Using continuity, there is $M>0$ such that $f(x)>\frac{\ell}{2}$ for all $x\geq M$. Therefore, $$\int_{\mathbb R} f(x)dx=\int_{|x|>M}f(x)+\int_{[-M,M]}f(x)\geq \frac{\ell}{2}\int_{|x|>M}dx+C=+\infty ,$$
what contradict $f$ integrable. 
Q1) Is it correct ?
Q2) How can I do if I don't suppose that $\lim_{|x|\to \infty }f(x)$ exist ?

The idea of the argument is this: an integrable function that does not tend to zero may have thinner and thinner pikes, and the integral on each pike needs to tend to zero. If the function is uniformly continuous, these pikes can't get thinner and thinner, and the function can't be integrable, as the integral on pikes does not tend to zero.
I'll consider $\Bbb R^+$ here, but the same argument works with $\Bbb R^-$, hence $\Bbb R$.
Suppose $f$ is uniformly continuous on $\Bbb R^+$ and $f(x)$ does not tend to zero as $x\to+\infty$. Let's prove it's not integrable.
Since $f$ does not converge to zero, there is an $\varepsilon>0$ such that you can define an increasing sequence $x_n\to+\infty$ such that $|f(x_n)|>\varepsilon$.
Since $f$ is uniformly continuous, for this $\varepsilon$, there is a $\delta>0$ such that $|x-y|<\delta\implies|f(x)-f(y)|<\varepsilon/2$.
That means that on every interval $]x_n-\delta,x_n+\delta[$, $|f(x)|>\varepsilon/2$. Hence the area under the curve on this interval is larger that $\delta\varepsilon>0$, and that does not depend on $n$.
Therefore $\int_{x_n-\delta}^{x_n+\delta}f(u)du$ does not tend to zero as $n\to+\infty$, and the function $h(x)=\int_0^{x}f(u)du$ can't converge as $x\to+\infty$, hence the function $f$ is not integrable.
