Advertisement
Rongusha

Untitled

Sep 19th, 2019
286
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.53 KB | None | 0 0
  1. using System;
  2.  
  3. namespace Scolarship
  4. {
  5. class Program
  6. {
  7. static void Main(string[] args)
  8. {
  9. double incomeLv = double.Parse(Console.ReadLine());
  10. double grade = double.Parse(Console.ReadLine());
  11. double minIncomeLv = double.Parse(Console.ReadLine());
  12.  
  13. double socialScolarship = Math.Floor(minIncomeLv * 0.35);
  14. double gradeScolarship = Math.Floor(grade * 25);
  15.  
  16. if ((incomeLv >= minIncomeLv && grade < 5.50) || (incomeLv <= minIncomeLv && grade < 4.50))
  17. {
  18. Console.WriteLine("You cannot get a scholarship!");
  19. }
  20. else if (incomeLv <= minIncomeLv && (grade < 5.50 && grade >= 4.50))
  21. {
  22.  
  23. Console.WriteLine($"You get a Social scholarship {socialScolarship} BGN");
  24. }
  25. else if ( grade >= 5.50 )
  26. {
  27.  
  28. Console.WriteLine($"You get a scholarship for excellent results {gradeScolarship} BGN");
  29. }
  30. else if (incomeLv <= minIncomeLv && grade >= 5.50)
  31. {
  32. if (gradeScolarship > socialScolarship)
  33. {
  34. Console.WriteLine($"You get a scholarship for excellent results {gradeScolarship} BGN");
  35.  
  36. }
  37. else if (socialScolarship > gradeScolarship)
  38. {
  39. Console.WriteLine($"You get a Social scholarship {socialScolarship} BGN");
  40. }
  41.  
  42. }
  43.  
  44. }
  45. }
  46. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement