cin & cout is slow?
· â 3 min read · đĻ Kyle
is or why is cin, cout slow in C++?
A segment tree is a binary tree where each node represents an interval. Each node stores some property of its corresponding interval: like the maximum/minimum num, the sum of that interval.