Ticket 4354
Problem 1661 -c
Submission 153218088
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
8
8
4 4 1 6 7 5 2 8 
5
9 1 4 2 4 
9
9 1 5 5 9 6 4 2 6 
6
5 2 7 4 5 7 
1
4 
3
8 1 7 
5
7 4 2 6 6 
8
7 8 2 3 2 4 5 7 
Expected Output
18
17
23
8
0
6
7
18
Your Output
18
17
23
8
0
6
6
18
Difference
Generator Parameters
--h_high 9 --h_low 1 --n_high 9 --n_low 1 --t_high 10 --t_low 1