Im a newbie, I can get past this step. Please help.

Hi there. Can someone pls help. I have checked this code over and over again and can not see any errors. Task 6: Control Structures - Conditional Statements*/ // Define a variable named studentGrade that is of type number. let studentGrade = 70; function gradeCommentary() { // 1. If studentGrade is above or equal to 90, log "Excellent work!". if (studentGrade >= 90) { console.log("Excellent work!"); } // 2. If studentGrade is between 80 and 89 (inclusive), log "Good job!" else if (studentGrade >= 80 && studentGrade <= 89) { console.log("Good job!"); } // 3. If studentGrade is between 70 and 79 (inclusive), log "You passed.". else if (studentGrade >= 70 && studentGrade <= 79) { console.log("You passed."); } // 4. If studentGrade is below 70, log "Needs improvement.". else { console.log("Needs improvement."); } }
5 Replies
BrandingLab
BrandingLabOP8mo ago
???
Web Bae
Web Bae8mo ago
Hey @BrandingLab - the code looks good from here - can you share the error you are getting? Maybe a screenshot? Hey @BrandingLab I just copy/pasted all of your code in a new project for this lesson and all the tests for Task 6 passed.
Web Bae
Web Bae8mo ago
No description
Web Bae
Web Bae8mo ago
this suggests to me there's an issue with the installation or the test file that may have been made inadvertently. We can hop on a call if that would help!
BrandingLab
BrandingLabOP8mo ago
yes please
Want results from more Discord servers?
Add your server