MCPcopy Create free account
hub / github.com/TheAlgorithms/Python / segment_tree_other.py

File segment_tree_other.py

data_structures/binary_tree/segment_tree_other.py:None–None  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1"""
2Segment_tree creates a segment tree with a given array and function,
3allowing queries to be done later in log(N) time
4function takes 2 values and returns a same type value

Callers

nothing calls this directly

Calls 4

traverseMethod · 0.80
query_rangeMethod · 0.80
SegmentTreeClass · 0.70
updateMethod · 0.45

Tested by

no test coverage detected