Hotel room
Здравейте искам да разбера защо ми дава 60/100 на задачата hotel room ето го и кода:
namespace ConsoleApp9
{
internal class Program
{
static void Main(string[] args)
{
string month = Console.ReadLine();
int stay = int.Parse(Console.ReadLine());
double totalCostStudio = 0;
double totalCostApart = 0;
if (stay > 200)
{
}
if (month == "May" || month == "October")
{
if (stay > 7 && stay < 14)
{
totalCostApart = stay * 65;
totalCostStudio = (stay * 50) * 0.95;
}
if (stay > 14)
{
totalCostApart = (stay * 65) * 0.9;
totalCostStudio = (stay * 50) * 0.7;
}
else
{
totalCostApart = stay * 65;
totalCostStudio = stay * 50;
}
}
if (month == "June" || month == "September")
{
if (stay > 14)
{
totalCostApart = stay * 0.9;
totalCostStudio = (stay * 75.2) * 0.8;
}
else
{
totalCostApart = stay * 68.7;
totalCostStudio = stay * 75.2;
}
}
if (month == "July" || month == "August")
{
totalCostStudio = stay * 76;
if (stay > 14)
{
totalCostApart = (stay * 77) * 0.9;
}
else
{
totalCostApart = stay * 77;
}
}
else
{
}
Console.WriteLine($"Apartment: {totalCostApart:f2} lv.");
Console.WriteLine($"Studio: {totalCostStudio:f2} lv.");
}
}
}