<s>[INST] Show that $f\in \mathcal{R}[0,1]$ Let $f$ be defined by 
$$f(x) =\left\{\frac{1}{n}, \frac{1}{n+1} \lt x \le \frac{1}{n} \right\}$$ and $f(x) = 0$ when $x=0$ and $n \in N$. Show that $f$ is integrable and $$\int_{0}^{1}f(x)dx=\frac{\pi^2}{6}-1.$$
 [/INST] Hint : 
Suppose it is integrable can you relate that integral (Draw  a picture) to following sum 
$$\frac{1}{2}+(\frac{1}{2}-\frac{1}{3})\cdot \frac{1}{2}+(\frac{1}{3}-\frac{1}{4})\cdot \frac{1}{3}+(\frac{1}{4}-\frac{1}{5})\cdot \frac{1}{4}+\cdots$$
This should immediately give you required result.
</s>