Going Shopping with Grandma (I)

Problem Number: 
13 061
Type of Problem: 
Problem Category: 
Input: 
Random Input
0
0
Critical Input: 
Random Input: 
918 713 717 299 390 819 0 1000 33 184 241 703 582 916 929 789 198 252 704 902 93 942 254 496 549 490 14 994 885 435 828 732 1000 0 622 609 644 12 1 1 39 3 64 919 38 974 343 428 766 717 471 601 326 407 1000 1000 961 37 904 612 953 784 218 112 645 236 725 313 146 762 152 224 971 323 187 198 122 964 514 961 16 952 551 352 534 210 528 879 235 480 689 24 622 156 193 596 481 152 765 587 0 0
Problem Id: 
13061