cf/mirror

Omkar and Medians

CF
1536D2000· candidate master2s256 MB⌨ stdin/stdout

Examples

Sample 1of 2
Input
5
4
6 2 1 3
1
4
5
4 -8 5 6 -7
2
3 3
4
2 1 2 3
Output
NO
YES
NO
YES
YES
Sample 2of 2
Input
5
8
-8 2 -6 -5 -4 3 3 2
7
1 1 3 1 0 -2 -1
7
6 12 8 6 2 6 10
6
5 1 2 3 6 7
5
1 3 4 3 0
Output
NO
YES
NO
NO
NO
1536D.cpp
loading editor…
Ln 11·137 BGNU C++20 (64)