While solving NOV17 SEGPROD I stumbled upon this comment on codeforces. Talking about a Data Structure like Sparse Table that can answer range sum query in heta(1). But the comment only talked about how to answer query in heta(\log n).

Though my naive implementation of the heta(\log n) approach did solve the problem without requiring many optimizations. I was wondering if anyone has heard of this DS before and knows the approach to solve it in heta(1).