Let $f$ be the following function from $\mathbb{R} \rightarrow \mathbb{Z}: f(x) = m$ where m is the unique integer such that $m \le x < m+1$. In other words, $f(x)$ is equal to the largest integer that is less than or equals to x. For instance, $f(2.3) = 2$, $f(1) = 1$, $f(-1.37) = -2$. Prove f is an increasing function.
I know that the definition of increasing function is "if for any $x,y \in A$ such that $x \le y$, we have $f(x) \le f(y)$." I have this unorganized ideas how to prove this problem, and I'm not sure how to proceed.
Let $x \le y$. Set $f(x) = m$ and $f(y) = n$ where $m \le x < m+1$ and $n \le y < n+1$. Then, we have $f(y)-f(x) = n - m$. Since $y \ge x$, we have $n - m \le y - x < n + 1 - m -1 \Rightarrow n - m \le y - x < n - m$. Hence, $f(y)-f(x) = n - m = y - x$.
I don't know how to connect this idea to show that $f(x) \le f(y)$. How do I go to next part? Do I even have the right idea?
EDIT
the definition of increasing function is "if for any $x,y \in A$ such that $x < y$, we have $f(x) \le f(y)$."
Here's my proof with the right definition.
Let $x < y$. Set $f(x) = m$ and $f(y) = n$ where $m \le x < m+1$ and $n \le y < n+1$. Then, we have $f(y)-f(x) = n - m$. Since $y > x$, we have $n - m \le y - x < n + 1 - m -1 \Rightarrow n - m \le y - x < n - m$. Hence, $f(y)-f(x) = n - m = y - x$. Since $y > x$, we have $f(y)-f(x) > 0$. Therefore, $f$ is an increasing function.
I don't know if this does make sense..