6099 - 逃亡的准备
时间限制 : 1 秒
内存限制 : 128 MB


输入

输出

样例
输入
2 10 3 4 3 2 2 5
输出
13
来源
一本通
2 10 3 4 3 2 2 5
13
一本通