Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- namespace FilmPremiere
- {
- class Program
- {
- static void Main(string[] args)
- {
- string movie = Console.ReadLine();
- string moviePack = Console.ReadLine();
- int ticket = int.Parse(Console.ReadLine());
- double sum = 0;
- switch (movie)
- {
- case "John Wick":
- switch (moviePack)
- {
- case "Drink":
- sum += 12;
- break;
- case "Popcorn":
- sum += 15;
- break;
- case "Menu":
- sum += 19;
- break;
- }
- break;
- case "Star Wars":
- switch (moviePack)
- {
- case "Drink":
- sum += 18;
- break;
- case "Popcorn":
- sum += 25;
- break;
- case "Menu":
- sum += 30;
- break;
- }
- break;
- case "Jumanji":
- switch (moviePack)
- {
- case "Drink":
- sum += 9;
- break;
- case "Popcorn":
- sum += 11;
- break;
- case "Menu":
- sum += 14;
- break;
- }
- break;
- }
- if (movie == "Star Wars" && ticket >= 4)
- {
- sum *= 0.7;
- }
- else if (movie == "Jumanji" && ticket == 2)
- {
- sum *= 0.85;
- }
- Console.WriteLine($"Your bill is {sum * ticket:F2} leva.");
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement