Scholarship ПОМОЩ!
От вчера така и не разбрах къде греша.Може би ми трябват повече if-ве за да разгледам напълно всички неща.
МОЛЯ, ако намерите грешката и ме поправите ,то тя да бъде и обяснена.
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace if_4
{
class Program
{
static void Main(string[] args)
{
double dohod = double.Parse(Console.ReadLine());
double sredenuspeh = double.Parse(Console.ReadLine());
double minzaplata = double.Parse(Console.ReadLine());
double uspeh1 = sredenuspeh * 25;
double social1 = 35.0 / 100 * minzaplata;
if (dohod > minzaplata && sredenuspeh <= 5.50)
{
Console.WriteLine("You cannot get a scholarship!");
}
else if (dohod < minzaplata && sredenuspeh > 4.50 && uspeh1 < social1)
{
double social = 35.0 / 100 * minzaplata;
Console.WriteLine("You get a Social scholarship {0:f0} BGN", social1);
}
else if (sredenuspeh >= 5.50 && uspeh1 > social1)
{
double uspeh = sredenuspeh * 25;
Console.WriteLine("You get a scholarship for excellent results {0:f0} BGN", uspeh1);
}
}
}
}
Благодаря за пълния и полезен отговор.Колкото до кода, целта е аз да се науча.Ще опитам отново тази вечер.
Браво само така !