CSS C++ Functions

CSS C++ Functions

KG

21 Qs

quiz-placeholder

Similar activities

User Defined Functions

User Defined Functions

12th Grade

20 Qs

JAVA method

JAVA method

12th Grade

21 Qs

Python Functions

Python Functions

9th Grade

20 Qs

Arduino Basics

Arduino Basics

9th - 12th Grade

20 Qs

Functions

Functions

University

20 Qs

Functions

Functions

9th - 12th Grade

20 Qs

C++ Function

C++ Function

10th Grade

20 Qs

STATIC KEYWORD IN JAVA

STATIC KEYWORD IN JAVA

9th - 12th Grade

18 Qs

CSS C++ Functions

CSS C++ Functions

Assessment

Quiz

Computers

KG

Easy

Created by

Raphael Antonio

Used 2+ times

FREE Resource

21 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

1. What is another name for a function in C++?

a. Module

b. Method

c. Procedure

d. All of the above

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

2. What is the purpose of a function in C++?

a. To perform a certain action

b. To reuse code

c. To divide complicated programs into manageable components

d. All of the above

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

3. Which of the following is a pre-defined function in C++?

a. myFunction()

b. main()

c. findSum()

d. swap()

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

4. What is the syntax for creating a function in C++?

a. void myFunction() { //code to be executed }

b. void myFunction() ( //code to be executed )

c. void myFunction() [ //code to be executed ]

d. void myFunction() < //code to be executed >

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

5. What is the purpose of a default value for a parameter in a function?

a. To make the parameter optional

b. To ensure that the parameter is always passed

c. To make the function run faster

d. None of the above

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

6. What is the purpose of passing a reference to a function?

a. To change the value of the arguments

b. To make the function run faster

c. To ensure that the arguments are always passed

d. None of the above

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

7. Which of the following is not a benefit of using functions in C++?

a. Reusability

b. Divide and conquer

c. Components

d. Increased complexity

Create a free account and access millions of resources

Create resources
Host any resource
Get auto-graded reports
or continue with
Microsoft
Apple
Others
By signing up, you agree to our Terms of Service & Privacy Policy
Already have an account?