Time limit 2000/4000/4000/4000 ms. Memory limit 65000/65000/65000/65000 Kb. Prepared by Ibrahim Mesecan.
Total invoice amount
Shqip
Mr. Alban Shehu runs GSS "Gezer Shoe Store". He wants to prepare a program for his invoices to calculate the total
price.
Input specification
There are at least 1 and at most 10000 lines of input ending with a negative number. There are two integer
numbers in every line: unitPrice and n .
where unitPrice is the unit price of the given shoe type and it's 1 ≤ price ≤ 100
n is the number of shoe pairs for this type and 1 ≤ n ≤ 1000.
The entry ends with a negative number .
Output specification
You will calculate and give one number:
the sum of the invoice
Sample Input:
3 5
2 6
-1
Sample Output:
27
Для отправки решений необходимо выполнить вход.
|