Segment Trees-Optimization Lazy Propagation

Sir the code provided by Prateek Bhaiya,s lecture is not giving any output on running while on gfg ide it is displaying 1 1 1 1 1 1. But on hackerblocks IDE it is running fine with correct output why? Please resolve this problem as soon as possible as possible as it is interrupting my learning.
Bhaiya Code-https://ide.codingblocks.com/s/4401