Moved closing code to line 961
parent
8722a0a294
commit
0cab1ebfe5
|
@ -958,12 +958,12 @@
|
|||
"We can use if statements in JavaScript to only execute code if a certain condition is met.",
|
||||
"if statements require some sort of boolean condition evaluate.",
|
||||
"Example:",
|
||||
"<code> if (1 == 2) {",
|
||||
"<code> if (1 == 2) {</code>",
|
||||
"<code>  return(true);</code>",
|
||||
"<code>}</code>",
|
||||
"<code>else {</code>",
|
||||
"<code>  return(false);</code>",
|
||||
"<code>}</code></code>",
|
||||
"<code>}</code>",
|
||||
"Let's use <code>if</code> and <code>else</code> statements to make a coin-flip game.",
|
||||
"Create an <code>if-else statement</code> to return <code>heads</code> if the flip var is zero and to return <code>tails</code> if it's not."
|
||||
],
|
||||
|
|
Loading…
Reference in New Issue