Ticket 6111
Problem 1672 -d
View hacks & all small testcases

Unable to dry run this testcase?
Try making a new request with small values of n_high, t_high, *_high, etc.


Retry
Input
10
4
2 4 3 4 
3 4 2 4 
1
1 
1 
1
1 
1 
4
1 3 3 3 
3 3 1 3 
3
3 1 1 
3 1 1 
3
1 2 2 
1 2 2 
9
3 2 3 5 5 3 7 2 6 
3 3 7 2 6 2 5 3 5 
9
9 6 2 1 7 3 1 4 3 
4 7 1 2 3 9 6 1 3 
8
6 7 3 4 2 5 4 6 
4 4 6 3 7 5 2 6 
2
2 2 
2 2 
Expected Output
NO
YES
YES
NO
YES
YES
NO
NO
NO
YES
Generator Parameters
--n_high 9 --n_low 1 --t_high 10 --t_low 1