cf/mirror

Anya and the Mysterious String

CF
1881G2000· candidate master3s256 MB⌨ stdin/stdout

Examples

Sample 1of 1
Input
5
12 8
tedubcyyxopz
2 2 5
1 4 8 2
2 1 7
1 3 5 40
1 9 11 3
1 10 10 9
2 4 10
2 10 12
10 4
ubnxwwgzjt
2 4 10
2 10 10
1 6 10 8
2 7 7
11 3
hntcxfxyhtu
1 4 6 1
2 4 10
1 4 10 21
13 2
yxhlmzfhqctir
1 5 9 3
1 8 13 15
2 3
bp
1 1 2 15
1 1 2 18
1 2 2 1000000000
Output
YES
NO
NO
YES
NO
YES
YES
YES
1881G.cpp
loading editor…
Ln 11·137 BGNU C++20 (64)