cf/mirror

Unequal Adjacent Elements

CF
1762G3100· legendary gm2s256 MB⌨ stdin/stdout

Examples

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