Hellow all i do not understand this code. After execution "i" took 129 value. I think "i" must take value of 24. What happening to me can you explain it?

var i=0;
function run(){
Barperiod=60;
StartDate=20170201;
EndDate=20170202;
i=i+1;
printf("Result=%.f",i);
}