Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- using System.Threading.Tasks;
- namespace Currency_Converter
- {
- class Program
- {
- static void Main(string[] args)
- {
- double sum = double.Parse(Console.ReadLine());
- string inCurrance = Console.ReadLine();
- string outCurrance = Console.ReadLine();
- if (inCurrance == "BGN")
- {
- if (outCurrance == "EUR")
- {
- double bank = sum * 1.95583;
- Console.WriteLine("You hava " + Math.Round(bank, 2) + " leva");
- }
- if (outCurrance == "USD")
- {
- double bank2 = sum * 1.79549;
- Console.WriteLine("You have " + Math.Round(bank2, 2) + " leva");
- }
- if (outCurrance == "GBR")
- {
- double bank3 = sum * 2.53405;
- Console.WriteLine("You have " + Math.Round(bank3, 2) + " leva");
- }
- }
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement