A fair die is rolled independently 3 times.
Define
$X_i =$ 1 if the i-th roll yields a perfect square $0$ otherwise.
Suppose $Y$ = $X_1 + X_2 + X_3$.
Find the p.m.f.of Y and its d.f.
I found P($X_i$=1) = $19/27$ and P($X_i$=0)=$8/27$ , P(Y) = $0$ when y=0 P(Y) = when $0$<=Y<1 answer is not coming correct.
In your comment you correctly note that the probability that a single roll shows a perfect square (i.e. a $1$ or $4$) is $2/6 = 1/3$. Therefore we have $$P(X_i = 1) = \frac13.$$
Assuming that each of the rolls is independent, then $Y = 0$ occurs only if all three rolls are $0$, i.e.
$$\mathbf P[Y = 0] = \mathbf P[ X_1 = X_2 = X_3 = 0] = \left( \frac23\right)^3 = \frac8{27}$$
Similarly $Y = 1$ if only one of the three dice show a $1$, i.e. \begin{align*} \mathbf P[Y = 1] &= \mathbf P[ X_1 =1, X_2 = X_3 = 0] + \mathbf P[ X_1 =0, X_2 =1,\, X_3 = 0] + \mathbf P[ X_1 = X_2 =0, \, X_3 = 1] \\ & = 3 \left(\frac13\right) \left(\frac23\right)^2 \\ & = \frac49 \end{align*}
Hopefully this now gives you a hint how to calculate the probabilities of $Y = 2$ and $Y= 3$.
If you are already familiar with the Binomial distribution then this is simply saying that $Y \sim \text{Bin}(3,p)$ with $p = \frac13$ the probability that a single roll is a perfect square.