vletm sir,sambit
to cell H6=IF(G6<>0,$E$2+G6,H5)
and copy down
Hans Sir,I would propose formulas like those shown in column P.
=LAMBDA(rws,start,toAdd,LET(ta,FILTER(toAdd,toAdd<>"",{0}),EXPAND(start,rws,,start)+EXPAND(ta,rws,,MAX(TAKE(ta,-1)))))(6,$E$2,J33:J38)
OK, did this, see attached column P:and maybe tweaked to allow non-contiguous values in column J
=LAMBDA(start,toAdd,LET(rws,ROWS(toAdd),ta,SCAN(0,toAdd,LAMBDA(a,b,IF(ISBLANK(b),a,b))),SEQUENCE(rws,,start,0)+ta))($E$2,J5:J10)
=LAMBDA(start,toAdd,SCAN(0,toAdd,LAMBDA(a,b,IF(ISBLANK(b),a,b)))+SEQUENCE(ROWS(toAdd),,start,0))($E$2,J33:J38)