https://codeforces.com/contest/1732/problem/E
i found a small bug while i was solving this problem. when i put my mouse on the second sample, the one corresponding in the first sample will also be highlighted, like this: it isn't something important, but i think i will still post this blog