https://codeforces.net/contest/1348/problem/F
I read the editorial.
https://codeforces.net/blog/entry/76555
Looking for an explanation to solution 2
Can anyone take test case 1 and draw the graph and show exactly how the cycles are formed in the diagram