Ticket 3635
Problem 1629 -c
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
4
9
5 9 1 3 4 4 9 6 6 
3
1 1 2 
4
1 3 3 3 
4
1 2 2 0 
Expected Output
9
0 0 0 0 0 0 0 0 0
3
0 0 0
4
0 0 0 0
1
3
Generator Parameters
--t_high 10