0
Where is my mistake?
function scholarship(income, grade, salary){ income =Number(income); grade = Number(grade); salary = Number(salary); let social = 0; let exelentGrade = 0; if ( income < salary && grade > 4.5){ social = salary * 0.35; } if (grade >= 5.5){ exelentGrade = grade * 25; }else{ console.log("You cannot get a scholarship!"); } if(social>exelentGrade){ console.log(`You get a Social scholarship ${Math.floor(social)} BGN`); } if(social<exelentGrade){ console.log(`You get a scholarship for excellent results ${Math.floor(exelentGrade)} BGN`); } } scholarship("480.00", "4.60", "450.00");
2 Answers
+ 1
Works fine according to inputs , what are your expected inputs and outputs tho?
0
We have a Judge sistem and it's giving me 75/100