Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- using System.Threading.Tasks;
- namespace Conditional
- {
- class Program
- {
- static void Main(string[] args)
- {
- double salary = double.Parse(Console.ReadLine());
- double average = double.Parse(Console.ReadLine());
- double minWage = double.Parse(Console.ReadLine());
- double socialScholar = 0;
- double excellentScholar = 0;
- if (average < 4.50)
- {
- Console.WriteLine("You cannot get a scholarship!");
- return;
- }
- if (minWage > salary && average > 4.5)
- {
- socialScholar = minWage * 0.35;
- excellentScholar = average * 25;
- if (average >= 5.5 && excellentScholar >= socialScholar)
- {
- Console.WriteLine($"You get a scholarship for excellent results {Math.Floor(excellentScholar)} BGN");
- return;
- }
- Console.WriteLine($"You get a Social scholarship {Math.Floor(socialScholar)} BGN");
- return;
- }
- else if (salary > minWage && average >= 5.5)
- {
- excellentScholar = average * 25;
- Console.WriteLine($"You get a scholarship for excellent results {Math.Floor(excellentScholar)} BGN");
- return;
- }
- else if (average >= 5.5)
- {
- excellentScholar = average * 25;
- Console.WriteLine($"You get a scholarship for excellent results {Math.Floor(excellentScholar)} BGN");
- return;
- }
- else
- {
- Console.WriteLine("You cannot get a scholarship!");
- return;
- }
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement