Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- namespace WorldSnookerChampionship
- {
- class Program
- {
- static void Main(string[] args)
- {
- string championshipEtap = Console.ReadLine();
- string ticketType = Console.ReadLine();
- int ticketsCount = int.Parse(Console.ReadLine());
- char photoWithTheTrophy = char.Parse(Console.ReadLine());
- double ticketPrice = 0;
- if (totalTicketPrice > 4000)
- {
- totalTicketPrice *= 0.75;
- }
- else if (totalTicketPrice > 2500)
- {
- totalTicketPrice *= 0.90;
- if (photoWithTheTrophy == 'Y')
- {
- totalTicketPrice += ticketsCount * 40;
- }
- }
- else if (photoWithTheTrophy == 'Y')
- {
- totalTicketPrice += ticketsCount * 40;
- }
- Console.WriteLine($"{totalTicketPrice:F2}");
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement