HomeVolumesContestsSectionsForumsUsersPrintHelpAbout

Contests > Lab10 - CEN ECE > problem:


15-Fall-01. 50806 - TVSH

Lab10 - CEN ECE

Start: Nov.28.2023 at 12:14:08 AM
Finish: Dec.14.2023 at 11:14:08 PM
The contest is finished!
• Contest scoreboard

Guest
• Review clarifications (1)

Contest problems

• 50394 - Water Bills
• 50733 - The Highest Average
• 50366 - Student Averages (2 Grades)
• 50501 - The Highest Average
• 50463 - Drawing a Triangle
• 50466 - Drawing Square From Stars
• 14-FallResit-10. 50537 - esreveR Tri...
• 14-Spr2-40. 50438 - Pattern with stars
• 15-Fall-01. 50806 - TVSH
• 15-FallHW-1. 50820 - Post Office
• 15-PE-3. 50867 - Average of the Be...
• 2013-04-60. 50295 - Weighted Aver...
• 9-P4. 50899 - How Many Years

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.
Question by Ibrahim Mesecan.

TVSH

Shqip

After the new TVSH (Value Added Tax) regulation, government is planning some changes now. There will be three types of taxes

  1. Medical expenses: 6%
  2. Educational expenses: 10%
  3. Others: 20%

Question: Write a program that gets the type and amount of n expenses, and then it calculates the total tax to be paid.

Input specification
You will be first given one integer(n). Then, in the following n lines, you will be given 2 integers (information for each expense):

  • the type: an integer between 1 and 3 ( 1 is Medical expense, etc.)
  • and the amount (base price before tax is added) an integer between 1 and 10,000
where 0 ≤ n ≤ 10,000.

Output specification
Show one number (with two digits after the floating point): total amount of tax to be paid.

Sample Input I
2
1 1000
3 500
Sample Input II
6
3 2000
2 1100
2 400
3 900
1 1900
3 500
Sample Output I
160
Sample Output II
944

Explanation for sample 1: The tax for the first item is 60leke and the tax for the second item is 100leke. So, the total amount of tax to be paid is 160leke.

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

www.contester.ru