Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- namespace ConsoleApp2
- {
- class Program
- {
- static void Main(string[] args)
- {
- string ticket = Console.ReadLine();
- int row = int.Parse(Console.ReadLine());
- int col = int.Parse(Console.ReadLine());
- double income = row * col;
- //Premiere-12.0,Normal-7.5,Discount-5.0
- switch (ticket)
- {
- case "Premiere":
- income = income*12.00;
- break;
- case "Normal":
- income *= 7.50;
- break;
- case "Discount":
- income *= 5.00;
- break;
- default:
- break;
- }
- //Console.WriteLine("{0:F2} leva", income);
- Console.WriteLine($"{income:F2} leva");
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement