Easter Decoration
https://softuni.bg/downloads/svn/programming-basics-v4/course-directories/may-2019/2019-03/Exam/06.%20Easter%20Decoration.pdf това е задачата може ли малко помощ. Ако може някай да ми обясни къде ми е грешката и как да я поправя ще съм много благодарен!
using System;
namespace EeasterDecoration
{
class Program
{
static void Main(string[] args)
{
int customerNumber = int.Parse(Console.ReadLine());
string command = string.Empty;
double wholeSum = 0;
for (int i = 0; i < customerNumber; i++)
{
double basket = 0;
double wreath = 0;
double chocolateBunny = 0;
while (command != "Finish")
{
command = Console.ReadLine();
if (command == "basket")
{
basket++;
}
else if (command == "wreath")
{
wreath++;
}
else if (command == "chocolate bunny")
{
chocolateBunny++;
}
}
double productNumber = basket + wreath + chocolateBunny;
double price = basket * 1.50 + wreath * 3.80 + chocolateBunny * 7;
if (productNumber % 2 == 0)
{
price = price - (price * 0.2);
}
Console.WriteLine($"You purchased {productNumber} items for {price:f2} leva.");
wholeSum += price;
}
Console.WriteLine($"Average bill per client is: {(wholeSum / customerNumber):f2} leva.");
}
}
}