cf/mirror

Annual Ants' Gathering

CF
1949C1900· candidate master2s256 MB⌨ stdin/stdout

Examples

Sample 1of 3
Input
7
5 1
3 2
4 6
3 6
7 1
1 3
Output
YES
Sample 2of 3
Input
5
1 4
4 2
3 2
5 3
Output
NO
Sample 3of 3
Input
6
4 5
5 6
6 1
2 6
3 2
Output
YES
1949C.cpp
loading editor…
Ln 11·137 BGNU C++20 (64)
loading graph engine…