TopCoder

User's AC Ratio

NaN% (0/0)

Submission's AC Ratio

NaN% (0/0)

Tags

Description

Input Format

Output Format

Sample Input 1

3 3 8 2
1 3 2
1 1 3 3 3 2 2 2

Sample Output 1

YES

Sample Input 2

3 3 6 2
1 3 2
1 3 3 3 2 2

Sample Output 2

NO

Sample Input 3

3 3 5 2
1 3 2
1 1 3 2 2

Sample Output 3

NO

Sample Input 4

1 2 3 1
1 1
1 1 1

Sample Output 4

YES

Sample Input 5

2 2 4 1
1 2
1 2 1 2

Sample Output 5

YES

Hints

Problem Source

ICPC 2026 Asia Seoul Regional Problem B

Subtasks

No. Testdata Range Score

Testdata and Limits

No. Time Limit (ms) Memory Limit (VSS, KiB) Output Limit (KiB) Subtasks
0 1000 1048576 1048576
1 1000 1048576 1048576
2 1000 1048576 1048576
3 1000 1048576 1048576
4 1000 1048576 1048576
5 1000 1048576 1048576
6 1000 1048576 1048576
7 1000 1048576 1048576
8 1000 1048576 1048576
9 1000 1048576 1048576
10 1000 1048576 1048576
11 1000 1048576 1048576
12 1000 1048576 1048576
13 1000 1048576 1048576
14 1000 1048576 1048576
15 1000 1048576 1048576
16 1000 1048576 1048576
17 1000 1048576 1048576
18 1000 1048576 1048576
19 1000 1048576 1048576
20 1000 1048576 1048576
21 1000 1048576 1048576
22 1000 1048576 1048576
23 1000 1048576 1048576
24 1000 1048576 1048576
25 1000 1048576 1048576
26 1000 1048576 1048576
27 1000 1048576 1048576
28 1000 1048576 1048576
29 1000 1048576 1048576
30 1000 1048576 1048576
31 1000 1048576 1048576
32 1000 1048576 1048576
33 1000 1048576 1048576
34 1000 1048576 1048576