Search Header Logo

C++ Math

Authored by John Miller

Computers

9th Grade

Used 1+ times

C++ Math
AI

AI Actions

Add similar questions

Adjust reading levels

Convert to real-world scenario

Translate activity

More...

    Content View

    Student View

10 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the syntax for finding the square root of a number in C++?

findSquareRoot(number)

sqrt(number)

squareRoot(number)

root(number)

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which library should be included to use the pow() function in C++?

iostream

cstring

cmath

cstdlib

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the result of the expression pow(2, 3) in C++?

10

8

6

4

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

How can you find the absolute value of a number in C++?

abs(number)

absoluteNumber(number)

absoluteValue(number)

absolute(number)

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the syntax for finding the maximum of two numbers in C++?

int maxNum = (num1 < num2) ? num1 : num2;

int maxNum = (num1 == num2) ? num1 : num2;

int maxNum = (num1 <= num2) ? num1 : num2;

int maxNum = (num1 > num2) ? num1 : num2;

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which library should be included to use the ceil() function in C++?

cstdlib

cmath

iostream

ctime

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the result of the expression ceil(4.3) in C++?

4

5

3

6

Access all questions and much more by creating a free account

Create resources

Host any resource

Get auto-graded reports

Google

Continue with Google

Email

Continue with Email

Classlink

Continue with Classlink

Clever

Continue with Clever

or continue with

Microsoft

Microsoft

Apple

Apple

Others

Others

Already have an account?