Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <!DOCTYPE html>
- <html lang="en">
- <head>
- <meta charset="UTF-8">
- <meta name="viewport" content="width=device-width, initial-scale=1.0">
- <meta http-equiv="X-UA-Compatible" content="ie=edge">
- <title>Document</title>
- <script>
- // #1
- //read the description of the six falsy types in the W3/MDN documentation
- // create six variables, and store one of the falsy datatypes in each.
- //#2
- //console log the typeOf for each variable that you created
- //note the types of the six falsy values which show up in the console
- //also note that all non falsy values are true values!
- //#3
- // Use "==" and "===" to compare strings numbers and numbers with same value
- // for example if(5 == "5") vs if(5 === "5")
- //console log the result, what do you notice in the console logs?
- // read the W3/MDN == vs === documentation on type coercien
- </script>
- </head>
- <body>
- </body>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement