How do I transform an r.v. using the floor function? (exponential distribution)

Hint:* $Y$ is clearly discrete taking values in the set of non-negative integers, due to the the flooring. Then, for any integer $n\geq 0$ we have $$P(Y = n) = P\left(X\in [an, a(n+1))\right) $$ $$= \int_{an}^{a(n+1)} \lambda\mathrm e^{-\lambda x}dx= (1-p)^np$$ where $p = 1 - e^{-\lambda a} \in (0,1),$ as $\lambda>0$ and $a>0$.


$Y$ takes on value $k \in \{0,1,\ldots,\}$ if $k = \lfloor \frac{X}{a} \rfloor$. Thus, $P(Y=k) = P( \lfloor \frac{X}{a} \rfloor = k) = P(k \leq \frac{X}{a} < k+1) = P(ak \leq X < a(k+1)) = \int_{ak}^{a(k+1)} f(x) dx$ where $f(x)$ is the density of $X$.