Prove that if $x$ is a real number, and $x-\lfloor x\rfloor \ge \frac{1}{2}$, then $\lfloor 2x\rfloor=2\lfloor x\rfloor +1$
I'm so confused because i don't completely understand the rules for floor but my textbook decided to ask a question using it even though no one in my class understand it i have gotten to the point suppose $x$ is a real number $r$ so that $\lfloor 2r\rfloor = \lfloor 2r\rfloor +1$. We can subtract the $2\lfloor r\rfloor$ to get $\lfloor 2r\rfloor-\lfloor 2r\rfloor = 1$ but i don't know where to go from there.
Hint: Write $x = \lfloor x \rfloor + r$ with $\frac{1}{2} \le r < 1$. Then
$$2x = 2\lfloor x \rfloor + 2r$$
But $1 \le 2r < 2$, so the integer part of this number is.....