# Control flow - exercise 3: FizzBuzz

**URL:** <https://forum.codewithmosh.com/t/control-flow-exercise-3-fizzbuzz/18521>\
**Category:** JavaScript\
**Created:** [March 4, 2023, 9:06am UTC](https://forum.codewithmosh.com/t/control-flow-exercise-3-fizzbuzz/18521 "2023-03-04T09:06:05Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![caesar](https://avatars.discourse-cdn.com/v4/letter/c/ecd19e/32.png) [@caesar](https://forum.codewithmosh.com/u/caesar)\
**Post date:** [March 4, 2023, 9:06am UTC](https://forum.codewithmosh.com/t/control-flow-exercise-3-fizzbuzz/18521/1 "2023-03-04T09:06:05Z")

</div>

here is a screenshot of the code I wrote

 ![Schermafbeelding 2023-03-04 om 10.00.48](https://us1.discourse-cdn.com/flex020/uploads/codewithmosh/original/2X/9/92e286df56817b63f0a9345576010f24310a2eac.png)

I tried to make the FizzBuzz exercise, but every number I fill in it says ‘Not a Number’  
does anyone know how I can fix this?

many thanks,

caesar

---

<div class="post-metadata">

**Author:** ![UniqueNospaceShort](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.codewithmosh.com/uniquenospaceshort/32/1814_2.png) [@UniqueNospaceShort](https://forum.codewithmosh.com/u/UniqueNospaceShort)\
**Post date:** [March 4, 2023, 10:30am UTC](https://forum.codewithmosh.com/t/control-flow-exercise-3-fizzbuzz/18521/2 "2023-03-04T10:30:15Z")

</div>

You put semi colon after each `if` so it is an empty statement. The next line is `return "Not A Number"` which will happen every time. Hence the code under being vanished because it detected dead code. It will never get there.

Another hint is that the `return` statements are not indented from `if` statements while they should.

You seem to be using VS Code.

Use ⇧+Alt+F to format your document.  
Remove a semi-colon after an `if` statement and try again.  
Repeat.
