输入第一行包含两个正整数。第二行包含个正整数。
输出一个整数表示答案。
2 5 4 1
9
3 10 7 1 10
1
只有一种方案:10 10 10
原题链接:https://codeforces.com/gym/103388/problem/A