P(X=0)=.25

P(X=1)=.5

P(X=2)=.25

You can see the jumps at those point, which are the probabilities.

That is a sum of indicator functions that achieves one after 2.

Both of you comments are wrong.

At 1/2, only the first indicator is 1, hence F(.5)=1/4

At 3/2, the first two indicators are 1, hence F(1.5)=1/4+1/2=3/4.

Finally at 2 or afterwards F(x)=1/4+1/2+1/4=1