← Back to challenges

Fix the Expression

JavaScriptMediumbugslanguage_fundamentalsvalidation

Instructions

Fix the code in the Code tab so the function returns true if and only if x is equal to 7.

Examples

isSeven(4) ➞ false

isSeven(9) ➞ false

isSeven(7) ➞ true

Notes

The bug can be hard to find, so look closely!

javascript
Loading editor…
to run
Walks through the solution with reasoning and edge cases.
Next: Equality Check