Video editorial for problems D and E from the AtCoder Beginner Contest 217. I explain both segment tree and small to large based approaches for problem E.
Don't forget to subscribe to the channel. Let's get to 1k subscribers!
-----------------------------------------
My submissions (code):
Problem D: https://atcoder.jp/contests/abc217/submissions/25590161
Problem E (Small to Large): https://atcoder.jp/contests/abc217/submissions/25600361
Problem E (Segment Tree): https://atcoder.jp/contests/abc217/submissions/25595107
-----------------------------------------
Tutorial on small to large merging:
https://usaco.guide/plat/merging?lang=cpp
Tutorial on segment tree:
https://www.youtube.com/watch?v=_Xaz3QPbQYg