HomeVolumesContestsSectionsForumsUsersPrintHelpAbout

Sections > Arithmetic > problem:


50584 - Total invoice amount

Guest
• Review clarifications (1)

Section problems

• 50571 - Armstrong Numbers - 2
• 50572 - Palindromic Numbers
• 50574 - Triangular Numbers
• 50578 - Mersenne prime
• 50579 - Pentagonal Numbers
• 50581 - The roots of a quadratic eq...
• 50582 - Number of digits
• 50583 - Max of 3 numbers
• 50584 - Total invoice amount
• 50585 - Inner Product
• 50587 - Modular Conversion
• 50595 - Sum of the numbers
• 50599 - Sum of Squared Error (SSE...
• 50609 - Long division
• 50633 - The prime factors
• 50634 - Perfect numbers
• 50635 - Decomposition into terms

Feedback

If you notice incorrect translations in Contester, please let author know.

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


Для отправки решений необходимо выполнить вход.

www.contester.ru