Advertisement
Atanasov_88

Cinema

Jul 7th, 2015
504
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 0.86 KB | None | 0 0
  1. using System;
  2.  
  3.  
  4. namespace CinemaExercize
  5. {
  6.     class Program
  7.     {
  8.         static void Main()
  9.         {
  10.             string type = Console.ReadLine();
  11.             double rows = double.Parse(Console.ReadLine());
  12.             double columns = double.Parse(Console.ReadLine());
  13.  
  14.             double seats = rows * columns;
  15.  
  16.             double premiera = seats * 12;
  17.             double normal = seats * 7.5;
  18.             double discount = seats * 5;
  19.  
  20.             if (type == "Premiere")
  21.             {
  22.                 Console.WriteLine("{0:F2} leva", premiera);
  23.             }
  24.             if (type == "Normal")
  25.             {
  26.                 Console.WriteLine("{0:F2} leva", normal);
  27.             }
  28.             if (type == "Discount")
  29.             {
  30.                 Console.WriteLine("{0:F2} leva", discount);
  31.             }
  32.  
  33.            
  34.         }
  35.     }
  36. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement