User- Defined Functions Flashcards

1
Q

What will happen when we use a void in argument passing?

A

it will not return the value to the caller.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

In order to use the round function, we must include the _________ library

A

cmath library

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

A type of variable inside a function

A

Local Variables

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

When will we use the function overloading?

A

When we have multiple functions with the same name but different parameters

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

In C++, the function prototype is also known as _________________________

A

Function Decleration

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

To execute the codes of function, the user-defined function needs to be __________.

A

Invoked

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

If the user didn’t supply the user value means, then what value will the function take?

A

Default Value

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

How many minimum numbers of functions need to be present in a C++ program?

A

1 function

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

It refers to subprograms or procedure

A

Function

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

Which of the following is a complete function?

A

int funct(int x) { return x=x+1; }

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

It is the actual name of the function

A

Function name

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

Which value will it take when both user and default values are given?

A

The user value will be taken

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

When our function doesn’t need to return anything, it means that the parameter has a :

A

Blank space

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

is the ability to create multiple functions of the same name with different implementations.

A

Function Overloading

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

Where does the default parameter can be placed by the user?

A

Rightmost

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

How many parameters are there in the function: int add(int a,int b)?

A

2

17
Q

In C++, variables can be passed to a function by:

A

all pass by value, reference and pointer are used.