малък проблем със задача Transport price
double distance = double.Parse(Console.ReadLine());
string DayorNight = Console.ReadLine().ToLower();
double price = 0.0;
if (distance <= 20 && distance > 0)
{
if (DayorNight == "day")
{
price = 0.70 + (0.79 * distance);
}
else if (DayorNight == "night")
{
price = 0.70 + (0.90 * distance);
}
}else if (distance >= 20 && distance<100)
{
if(DayorNight == "day" || DayorNight == "night")
{
price = distance * 0.09;
}
}else if (distance >=100 && distance <= 5000)
{
if (DayorNight == "day" || DayorNight == "night")
{
price = distance * 0.06;
}
}
Console.WriteLine(price);
83 от 100