Math exam

Report a typo

Imagine that you want to study at a prestigious University, and you have to pass the math exam with a score no less than 90. For the function passingExam, create a promise that returns "You are enrolled!" in case of success, and "Sorry, you haven't passed the Math exam" otherwise.

Sample Input 1:

80

Sample Output 1:

Sorry, you haven't passed the Math exam
Write a program in JavaScript
function passingExam (myPoints) {
return new Promise(function() {
// write your function here
});
}
___

Create a free account to access the full topic