Упражнение: Проверки задача 8-ма *Стипендии 93 точки в judje. Просто не мога да намеря грешката
using System;
namespace stipendii_if_zadacha
{
class Program
{
static void Main(string[] args)
{
double income = double.Parse(Console.ReadLine());
double averageGrades = double.Parse(Console.ReadLine());
double minimalIncome = double.Parse(Console.ReadLine());
double socialScholarshipMoney = Math.Floor(minimalIncome * 0.35);
double exellentScholarshipMoney = Math.Floor(averageGrades * 25);
if ((income < minimalIncome) && (averageGrades > 4.5))
{
Console.WriteLine($"You get a Social scholarship {Math.Floor(socialScholarshipMoney)} BGN");
}
else if (averageGrades >= 5.5)
{
Console.WriteLine($"You get a scholarship for excellent results {Math.Floor(exellentScholarshipMoney)} BGN");
}
else if ((income < minimalIncome) && (averageGrades > 4.5) && (averageGrades >= 5.5))
{
if (socialScholarshipMoney > exellentScholarshipMoney)
{
Console.WriteLine($"You get a Social scholarship {Math.Floor(socialScholarshipMoney)} BGN");
}
else if (exellentScholarshipMoney >= socialScholarshipMoney)
{
Console.WriteLine($"You get a scholarship for excellent results {Math.Floor(exellentScholarshipMoney)} BGN");
}
}
else
{
Console.WriteLine("You cannot get a scholarship!");
}
}
}
}