I solved the problem using the Riemann integral. However, my answer did not match with the result given in the book. My answer was $\frac{3}{4}$ and the answer given in the book was just 3.
Help me understand where I went wrong. My solution
$$\lim_{n\to\infty} \sum_{i=1}^n \frac{1}{n}\cdot \lfloor \sqrt{\frac{4i}{n}}\rfloor =\lim_{n\to\infty} \sum_{i=1}^n \frac{1}{n} \cdot \lfloor 2\sqrt{\frac{i}{n}}\rfloor=$$ $$=\lim_{n\to\infty}\left(\frac{1}{n}\cdot \lfloor2\sqrt{\frac{1}{n}}\rfloor+\frac{1}{n}\cdot \lfloor2\sqrt{\frac{2}{n}}\rfloor+\ldots +\frac{1}{n}\cdot \lfloor2\sqrt{\frac{n}{n}}\rfloor\right)$$
Clearly, the given expression is a Riemann sum of the function $\lfloor2\sqrt{x}\rfloor$ on the interval $[0,1]$.
$$\lim_{n\to\infty} \sum_{i=1}^n \frac{1}{n}\cdot \lfloor \sqrt{\frac{4i}{n}}\rfloor =$$
$$=\int_0^1 \lfloor2\sqrt{x}\rfloor dx=\int_0^{\frac14} \lfloor2\sqrt{x}\rfloor dx+\int_{\frac14}^1 \lfloor2\sqrt{x}\rfloor dx=0+1\cdot\left(1-\frac14\right)=\frac34$$