In line no. 43, we should check the condition for 'i' and not 'n' right?

Since, we are using a bottom-up approach, and we are calculating the values for each ‘i’ starting from 2, we should be checking the condition for ‘i’.

@arsundram
ya you are right those if conditions should be on ‘i’.
Thanks for pointing it out.

The video will be replaced soon.

Ok! Thanks for the fast reply @sanyamsinghalmnnit

1 Like

@arsundram please mark this doubt as resolved for now.