Numbers & the Math Object

Numbers & the Math Object

Assessment

Interactive Video

Information Technology (IT), Architecture

University

Hard

Created by

Quizizz Content

FREE Resource

The video tutorial covers basic math operations using JavaScript, including addition, subtraction, multiplication, division, and modulus. It introduces the Math object and its properties, such as Pi and Euler's number, and demonstrates various Math methods like rounding, power, min/max, and generating random numbers. The tutorial concludes with a preview of the next video, which will focus on string manipulation.

Read more

7 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the result of adding NUM1 and NUM2 if NUM1 is 100 and NUM2 is 50?

100

200

150

50

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which property of the Math object returns the value of Pi?

Math.SQRT2

Math.LN2

Math.PI

Math.E

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What does Math.round(2.8) return?

3

4

2

2.5

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

How do you calculate the square root of a number using the Math object?

Math.floor()

Math.abs()

Math.pow()

Math.sqrt()

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the result of Math.pow(8, 2)?

64

16

32

8

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which method would you use to find the maximum value in a set of numbers?

Math.min()

Math.max()

Math.ceil()

Math.floor()

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

How can you generate a random integer between 1 and 20 using the Math object?

Math.round(Math.random() * 20)

Math.floor(Math.random() * 20) + 1

Math.ceil(Math.random() * 20)

Math.random() * 20