Published On Mar 7, 2024
In this series, I will solve the most beautiful problems of AtCoder. The solutions are truly elegant.
I solve this problem with 3 different solutions.
The first one uses DSU alongside parallel binary search.
The second one uses DSU + history.
The third one constructs a tree and uses that.
#atcoder #Atcoder_Solution #codeforces #codeforces_solution #competitive_programming #competitiveprogramming #algorithm #usaco #ioi #icpc
0:00 Intro
0:12 Problem Statement
1:13 Think about a Subtask
3:02 Improve the first solution using Parallel Binary Search
7:29 Second Awesome Solution (Online Solution)
11:00 The Third Awesome Solution
show more