Practice & Assessment
Test your understanding of Introduction to JavaScript
Multiple Choice Questions
5What is JavaScript primarily used for in web development?
Which JavaScript engine is used by the Google Chrome browser?
Where should a <script> tag be placed in an HTML file for best practice?
What does console.log() do in JavaScript?
What does 'use strict'; do at the top of a JavaScript file?
Coding Challenges
1Build a Personal Info Console Logger
Create a JavaScript file called profile.js. Declare variables for your name, age, city, and a boolean for whether you are a student. Use console.log() to print a formatted summary of your profile to the console. Run it with Node.js.
Mini Project
JavaScript Environment Setup and Hello World Page
Set up a complete local JavaScript development environment. Create an HTML file that links to an external JS file. In the JS file, use console.log() to print five different types of values: a string, a number, a boolean, the result of a math expression, and today's date using new Date(). Open the HTML file in Chrome and verify all five values appear in the console. Add at least three meaningful comments explaining what each block of code does.
