Problem I coins

In the video lecture, of I-coins, the base was

if(j==0)
return 1;

But if we toss i coins then the probability of getting 0 heads will be- getting all tails i.e. multiplying the probabilities of tails.
How can this be true for all N value, (only for 0 toss we can surely get 0 heads with prob 1).
Please correct me on this and help me with the logic.