ГлавнаяСборникиТурнирыРазделыФорумыУчастникиПечатьПомощьО системе

Разделы > Unsorted > задача:


50391 - Cinema Tickets

Гость
• Вопросы к жюри (4)

Задачи раздела

• 50284 - Knights of the Rook
• 50282 - Coins
• 50281 - Primes
• 50287 - Providers
• 50476 - Meditation
• 50879 - Passed or Failed
• 50428 - Three Times
• 50387 - Passengers in the Train
• 50391 - Cinema Tickets
• 50402 - Hello World!
• 50489 - Football Championship
• 51004 - Word Search Game
• 50430 - ATM
• 50426 - Calculating Sales
• 50425 - Calculating Weekly Pay
• 50438 - Pattern with stars
• 50820 - Post Office

Обратная связь

Если у вас есть предложения или пожелания по работе Contester, посетите форум сайта www.contester.ru.

Лимит времени 2000/4000/4000/4000 мс. Лимит памяти 65000/65000/65000/65000 Кб.
Prepared by Ibrahim Mesecan.

Cinema Tickets

Millennium Cinema center wants to start a computerized system. The ticket prices change according to the ages.

  • Between the ages 0 and 3: Free
  • Between the ages 4 and 9: $5
  • Over the age of 9: $8
The cashier, asks the age and gives the ticket.

Question:
Write a program that gets the ages of 3 people and calculates the total amount to be paid.

Input specification
You will be given three integer numbers (n) where the ages are integers between 0 and 120.

Output specification
Show just one integer number: total amount of money to be paid.

Sample Input I   
  6 1 9
Sample Input II   
  43 10 7
Sample Output I   
  10
Sample Output II  
  21


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

www.contester.ru