Международен валутен конвертор- вярна задача в ВС, но 0/100 точки в Джъдж
Здравейте,
проверявам задачата във VS и работи коректно, но в Judge ми дава 0 точки и не разбирам от къде е проблемът. Ето задачата:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Eli_tu
{
class Program
{
static void Main(string[] args)
{
double usd = 1.79549;
double eur = 1.95583;
double gbp = 2.53405;
double convertedCurrency;
double money = double.Parse(Console.ReadLine());
string currentCurrency = Console.ReadLine();
string requiredCurrency = Console.ReadLine();
if (currentCurrency == "usd" && requiredCurrency == "bgn")
{
convertedCurrency = money * usd;
Console.WriteLine(Math.Round(convertedCurrency, 2));
}
else if (currentCurrency == "usd" && requiredCurrency == "eur")
{
convertedCurrency = money * usd / eur;
Console.WriteLine(Math.Round(convertedCurrency, 2));
}
else if (currentCurrency == "usd" && requiredCurrency == "gbp")
{
convertedCurrency = money * usd / gbp;
Console.WriteLine(Math.Round(convertedCurrency, 2));
}
if (currentCurrency == "eur" && requiredCurrency == "bgn")
{
convertedCurrency = money * eur;
Console.WriteLine(Math.Round(convertedCurrency, 2));
}
else if (currentCurrency == "eur" && requiredCurrency == "usd")
{
convertedCurrency = money * eur / usd;
Console.WriteLine(Math.Round(convertedCurrency, 2));
}
else if (currentCurrency == "eur" && requiredCurrency == "gbp")
{
convertedCurrency = money * eur / gbp;
Console.WriteLine(Math.Round(convertedCurrency, 2));
}
if (currentCurrency == "gbp" && requiredCurrency == "bgn")
{
convertedCurrency = money * gbp;
Console.WriteLine(Math.Round(convertedCurrency, 2));
}
else if (currentCurrency == "gbp" && requiredCurrency == "eur")
{
convertedCurrency = money * gbp / eur;
Console.WriteLine(Math.Round(convertedCurrency, 2));
}
else if (currentCurrency == "gbp" && requiredCurrency == "usd")
{
convertedCurrency = money * gbp / usd;
Console.WriteLine(Math.Round(convertedCurrency, 2));
}
if (currentCurrency == "bgn" && requiredCurrency == "usd")
{
convertedCurrency = money / usd;
Console.WriteLine(Math.Round(convertedCurrency, 2));
}
else if (currentCurrency == "bgn" && requiredCurrency == "eur")
{
convertedCurrency = money / eur;
Console.WriteLine(Math.Round(convertedCurrency, 2));
}
else if (currentCurrency == "bgn" && requiredCurrency == "gbp")
{
convertedCurrency = money / gbp;
Console.WriteLine(Math.Round(convertedCurrency, 2));
}
}
}
}
Е, направо съм изумена, даде ми стоте точки- не мога да повярвам, че това е била причината.... и много благодаря :)