I want to evaluate $$ \lim_{x \to 0^+} x\left\lfloor x-\frac{1}{x} \right\rfloor $$One step in the proof involved writing $n=1/x$ and using the inequalities:
$$ \frac{n}{n+1} < -x\left\lfloor x-\frac{1}{x} \right\rfloor \leq \frac{n+1}{n} $$By the squeeze theorem, $$ \lim_{x \to 0^+} \left(-x \left\lfloor x-\frac{1}{x} \right\rfloor \right) = \lim_{n \to \infty} \frac{n}{n+1} = \lim_{n \to \infty}\frac{n+1}{n} = 1 $$ $$ \Rightarrow \qquad \lim_{x \to 0^+} x \left\lfloor x-\frac{1}{x} \right\rfloor = -1 $$
According to the solution above when $x \to 0^{+}$ then $n \to \infty$. Why is this the case here?