MCPcopy Create free account
hub / github.com/OpenGenus/cosmos / getSumUtil

Function getSumUtil

code/data_structures/src/tree/segment_tree/segment_tree.c:17–32  ·  view source on GitHub ↗

A recursive function to get the sum of values in given range of the array. The following are parameters for this function. st --> Pointer to segment tree index --> Index of current node in the segment tree. Initially 0 is passed as root is always at index 0 ss & se --> Starting and ending indexes of the segment represented by current node, i.e.,

Source from the content-addressed store, hash-verified

source not stored for this graph (policy: none)

Callers 1

getSumFunction · 0.85

Calls 1

getMidFunction · 0.70

Tested by

no test coverage detected