L. The Bag of Forgotten Coins
time limit per test
2 seconds
memory limit per test
1024 megabytes
input
standard input
output
standard output
Examples
Input
1
1
Output
1
Input
2
1 2
Output
2
Input
3
4 5 3
Output
7