Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- namespace FootballSouvenirs
- {
- class Program
- {
- static void Main(string[] args)
- {
- string country = Console.ReadLine();
- string souvenir = Console.ReadLine();
- int volume = int.Parse(Console.ReadLine());
- string print = "";
- double sum = 0;
- if (country == "Argentina")
- {
- if (souvenir == "flags")
- {
- sum = 3.25;
- }
- else if (souvenir == "caps")
- {
- sum = 7.20;
- }
- else if (souvenir == "posters")
- {
- sum = 5.10;
- }
- else if (souvenir == "stickers")
- {
- sum = 1.25;
- }
- else
- {
- print = "Invalid stock!";
- }
- }
- else if (country == "Brazil")
- {
- if (souvenir == "flags")
- {
- sum = 4.20;
- }
- else if (souvenir == "caps")
- {
- sum = 8.50;
- }
- else if (souvenir == "posters")
- {
- sum = 5.35;
- }
- else if (souvenir == "stickers")
- {
- sum = 1.20;
- }
- else
- {
- print = "Invalid stock!";
- }
- }
- else if (country == "Croatia")
- {
- if (souvenir == "flags")
- {
- sum = 2.75;
- }
- else if (souvenir == "caps")
- {
- sum = 6.90;
- }
- else if (souvenir == "posters")
- {
- sum = 4.95;
- }
- else if (souvenir == "stickers")
- {
- sum = 1.10;
- }
- else
- {
- print = "Invalid stock!";
- }
- }
- else if (country == "Denmark")
- {
- if (souvenir == "flags")
- {
- sum = 3.10;
- }
- else if (souvenir == "caps")
- {
- sum = 6.50;
- }
- else if (souvenir == "posters")
- {
- sum = 4.80;
- }
- else if (souvenir == "stickers")
- {
- sum = 0.90;
- }
- else
- {
- print = "Invalid stock!";
- }
- }
- else
- {
- print = "Invalid country!";
- }
- if (sum > 0)
- {
- Console.WriteLine($"Pepi bought { volume} { souvenir} of { country} for { sum * volume:f2} lv.");
- }
- else
- {
- Console.WriteLine(print);
- }
- }
- }
- }
Add Comment
Please, Sign In to add comment