Advertisement
Guest User

Oscars Week In Cinema

a guest
Apr 14th, 2019
968
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.58 KB | None | 0 0
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Text;
  5. using System.Threading.Tasks;
  6.  
  7. namespace Oscars_Week_In_Cinema
  8. {
  9. class Program
  10. {
  11. static void Main(string[] args)
  12. {
  13. string movie = Console.ReadLine();
  14. string hallType = Console.ReadLine();
  15. int ticketsSold = int.Parse(Console.ReadLine());
  16.  
  17. double ticketPrice = 0;
  18.  
  19. if (movie == "A Star Is Born")
  20. {
  21. if (hallType == "normal")
  22. {
  23. ticketPrice = 7.50;
  24. }
  25. else if (hallType == "luxury")
  26. {
  27. ticketPrice = 10.50;
  28. }
  29. else if (hallType == "ultra luxury")
  30. {
  31. ticketPrice = 13.50;
  32. }
  33. }
  34. if (movie == "Bohemian Rhapsody")
  35. {
  36. if (hallType == "normal")
  37. {
  38. ticketPrice = 7.35;
  39. }
  40. else if (hallType == "luxury")
  41. {
  42. ticketPrice = 9.45;
  43. }
  44. else if (hallType == "ultra luxury")
  45. {
  46. ticketPrice = 12.75;
  47. }
  48. }
  49. if (movie == "Green Book")
  50. {
  51. if (hallType == "normal")
  52. {
  53. ticketPrice = 8.15;
  54. }
  55. else if (hallType == "luxury")
  56. {
  57. ticketPrice = 10.25;
  58. }
  59. else if (hallType == "ultra luxury")
  60. {
  61. ticketPrice = 13.25;
  62. }
  63. }
  64. if (movie == "The Favourite")
  65. {
  66. if (hallType == "normal")
  67. {
  68. ticketPrice = 8.75;
  69. }
  70. else if (hallType == "luxury")
  71. {
  72. ticketPrice = 11.55;
  73. }
  74. else if (hallType == "ultra luxury")
  75. {
  76. ticketPrice = 13.95;
  77. }
  78. }
  79.  
  80. double moneyMade = ticketsSold * ticketPrice;
  81. Console.WriteLine($"{movie} -> {moneyMade:f2} lv.");
  82. }
  83. }
  84. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement