A task is given in which it is necessary to carry out bulk operations on a segment and recognize an element by index.
Mass operations are carried out as a sum calculation on a segment.
For each block, we store the change in that block, and when requesting an element from that block, we take that information into account.