Къде бъркам задача Fruit Shop
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace ConsoleApplication1
{
class Program
{
static void Main(string[] args)
{
var fruit = Console.ReadLine().ToLower();
var dayOfWeek = Console.ReadLine().ToLower();
var quantity = double.Parse(Console.ReadLine());
var result = 0.0;
if (dayOfWeek == "monday" || dayOfWeek == "tuesday" ||
dayOfWeek == "wednesday" || dayOfWeek == "thursday" || dayOfWeek == "friday")
{
if (fruit == "banana")
{
result = 2.50 * quantity;
}
else if (fruit == "apple")
{
result = 1.20 * quantity;
}
else if (fruit == "orange")
{
result = 0.85 * quantity;
}
else if (fruit == "grapefruit")
{
result = 1.45 * quantity;
}
else if (fruit == "kiwi")
{
result = 2.70 * quantity;
}
else if (fruit == "pineapple")
{
result = 5.50 * quantity;
}
else if (fruit == "grapes")
{
result = 3.85 * quantity;
}
else
{
Console.WriteLine("error");
}
}
if (dayOfWeek == "saturday" || dayOfWeek == "sunday")
{
if (fruit == "banana")
{
result = 2.70 * quantity;
}
else if (fruit == "apple")
{
result = 1.25 * quantity;
}
else if (fruit == "orange")
{
result = 0.90 * quantity;
}
else if (fruit == "grapefruit")
{
result = 1.6 * quantity;
}
else if (fruit == "kiwi")
{
result = 3.00 * quantity;
}
else if (fruit == "pineapple")
{
result = 5.60 * quantity;
}
else if (fruit == "grapes")
{
result = 4.20 * quantity;
}
else
{
Console.WriteLine("error");
}
}
Console.WriteLine(Math.Round(result, 2));
}
}
}