-->
当前位置:首页 > 题库

PROGRAMMING:The departure of ZF series

Luz5年前 (2021-05-10)题库489
After unlocking the password at the door, what appears in front of ZF is a dark hole. How can you give up for mm! ZF resolutely jumped into the hole... Nothing can be seen in the hole...
Fortunately, ZF has a torch on his body. Due to the shoddy work of unscrupulous manufacturers, the burning time of the torch is different. Now we know the total length of the cave L, the number of torches on ZF n, and the way that ZF can run when each torch can ignite.
In order to show in front of mm, ZF wants to tell mm how much distance he has groped in the dark, can you tell him?
(if ZF can run out of the cave before the torch is burned, output 0)
###Input format:
The total length of the cave is l, the number of torches on ZF is n, and the way ZF can run when each torch can ignite is Xi.
###Output format:
How long have you been groping in the dark
###Input example:
Here is a set of inputs. For example:
```in
2 2
one
one
```
###Output example:
The corresponding output is given here. For example:
```out
0
```
Tips
This group of test data input to the end of the file remember to use= EOF







answer:If there is no answer, please comment