Print series (last 3 outputs)

hey!
I am not getting the last 3 numbers in the series and can’t understand why.
Thank you

hello @akash_281
image
here instead of for loop use while loop.
connditon should be
while(count<n1)

also increase ur count variable only inside first if statement(i.e when u are printing)