2019 AMC 10B Problems/Problem 9

Revision as of 13:55, 14 February 2019 by Ironicninja (talk | contribs)

The function $f$ is defined by \[f(x) = \lfloor|x|\rfloor - |\lfloor x \rfloor|\]for all real numbers $x$, where $\lfloor r \rfloor$ denotes the greatest integer less than or equal to the real number $r$. What is the range of $f$?

$\textbf{(A) } \{-1, 0\} \qquad\textbf{(B) } \text{The set of nonpositive integers} \qquad\textbf{(C) } \{-1, 0, 1\} \qquad\textbf{(D) } \{0\} \qquad\textbf{(E) } \text{The set of nonnegative integers}$

Solution

There are 4 cases we need to test here:

Case 1: x is a positive integer. WLOG, assume x=1. Then f(1) = 1 - 1 = $0$.

Case 2: x is a positive fraction. WLOG, assume x=0.5. Then f(0.5) = 0 - 0 = $0$.

Case 3: x is a negative integer. WLOG, assume x=-1. Then f(-1) = 1 - 1 = $0$.

Case 4: x is a negative fraction. WLOG, assume x=-0.5. Then f(-0.5) = 0 - 1 = $-1$.

Thus the range of function f is $\boxed{A) {-1,0}}$

iron