here is my code for " Test your skills: Math".
Hi again
Well done!
Here are my comments:
- Task 1: Your even/odd test is wrong.
typeof
returns the string “number” which later always fails the testevenOddResult === 0
. You need to use the modulo operator (%). - Task 2: Correct!
- Task 3: Correct!
As a general advice:
Always use
const
where possible, only uselet
where necessary.
I hope that helps.
Cheers,
Michael
2 Likes
just updated my code regarding your comment.
I really do appreciate for your support.
2 Likes
Thanks. I’m glad it’s helpful.
Now the code is correct.
2 Likes