GMetrix Javascript Domain 2 UPDATED
ACTUAL Exam Questions and CORRECT
Answers
Push - CORRECT ANSWER - Adds an item to an array
Pop - CORRECT ANSWER - Removes the last item from an array
Shift - CORRECT ANSWER - Removes first item from an array
Unshift - CORRECT ANSWER - Adds one or more elements to the beginning of an array
What do you need to make a multi-dimensional array? - CORRECT ANSWER - For loops
Math.random() - CORRECT ANSWER - Returns a random number between 0 and 1
Math.round() - CORRECT ANSWER - Rounds a number to the nearest whole number
Math.abs() - CORRECT ANSWER - Makes a number represent its absolute value
Floor method aka Math.floor() - CORRECT ANSWER - Used to change numbers to the
nearest lower whole number
Ceiling method aka Math.ceil() - CORRECT ANSWER - Used to change numbers to the
nearest highest whole number
Math.pow() - CORRECT ANSWER - Raises number to a specified number
(Remember to put ,Number) to specify what power you are raising it to