Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- namespace World_Snooker_Championship
- {
- class Program
- {
- static void Main(string[] args)
- {
- string tournamentType = Console.ReadLine();
- string biletType = Console.ReadLine();
- int biletCount = int.Parse(Console.ReadLine());
- string photoWithCup = Console.ReadLine();
- double totalSumBilets = 0;
- if (biletType == "Standard")
- {
- if (tournamentType == "Quarter final")
- {
- totalSumBilets = biletCount * 55.50;
- }
- else if (tournamentType == "Semi final")
- {
- totalSumBilets = biletCount * 75.88;
- }
- else if (tournamentType == "Final")
- {
- totalSumBilets = biletCount * 110.10;
- }
- }
- else if (biletType == "Premium")
- {
- if (tournamentType == "Quarter final")
- {
- totalSumBilets = biletCount * 105.20;
- }
- else if (tournamentType == "Semi final")
- {
- totalSumBilets = biletCount * 125.22;
- }
- else if (tournamentType == "Final")
- {
- totalSumBilets = biletCount * 160.66;
- }
- }
- else if (biletType == "VIP")
- {
- if (tournamentType == "Quarter final")
- {
- totalSumBilets = biletCount * 118.90;
- }
- else if (tournamentType == "Semi final")
- {
- totalSumBilets = biletCount * 300.40;
- }
- else if (tournamentType == "Final")
- {
- totalSumBilets = biletCount * 400;
- }
- }
- if (totalSumBilets > 4000 && photoWithCup == "Y")
- {
- totalSumBilets = totalSumBilets - 0.25 * totalSumBilets;
- }
- else if (totalSumBilets > 2500 && totalSumBilets <= 4000 && photoWithCup == "Y")
- {
- totalSumBilets = totalSumBilets - (0.10 * totalSumBilets) + biletCount * 40;
- }
- Console.WriteLine($"{totalSumBilets:f2}");
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement