JavaScript Fundamentals Quiz
Test your knowledge of JavaScript basics. Please answer all questions to the best of your ability.
Full Name
*
First Name
Last Name
Email Address
*
example@example.com
Which keyword is used to declare a variable in JavaScript?
*
var
let
const
All of the above
What is the output of the following code? console.log(typeof null);
*
"null"
"object"
"undefined"
"number"
Select all valid JavaScript data types:
*
String
Number
Boolean
Float
Object
Undefined
Other
The
Statement
statement is used to exit a loop early in JavaScript.
Which of the following is the correct way to write a function in JavaScript?
*
function myFunction() {}
def myFunction() {}
function:myFunction() {}
func myFunction() {}
What will be logged to the console? let arr = [1,2,3]; console.log(arr[1]);
*
1
2
3
undefined
Which of these is NOT a JavaScript loop structure?
*
for
while
repeat-until
do...while
Match each JavaScript method to its description.
*
Rows
push
pop
shift
push
Adds an element to the end of an array
Removes the last element from an array
Returns the first element of an array
Sorts the array
Adds an element to the end of an array
Removes the last element from an array
Returns the first element of an array
Sorts the array
Adds an element to the end of an array
Removes the last element from an array
Returns the first element of an array
Sorts the array
pop
Adds an element to the end of an array
Removes the last element from an array
Returns the first element of an array
Sorts the array
Adds an element to the end of an array
Removes the last element from an array
Returns the first element of an array
Sorts the array
Adds an element to the end of an array
Removes the last element from an array
Returns the first element of an array
Sorts the array
shift
Adds an element to the end of an array
Removes the last element from an array
Returns the first element of an array
Sorts the array
Adds an element to the end of an array
Removes the last element from an array
Returns the first element of an array
Sorts the array
Adds an element to the end of an array
Removes the last element from an array
Returns the first element of an array
Sorts the array
Briefly explain what an object is in JavaScript.
Submit Quiz
Should be Empty: