Functions
- What is the output of this program?
#include
using namespace std;
void fun()
void fun()
{
cout<<"Inteview Mania";
}
int main()
{
fun();
return 0;
}
-
View Hint View Answer Discuss in Forum
NA
Correct Option: D
We have to use the semicolon to declare the function in line 3. If we did means, the program will execute.
- Which is more effective while calling the functions?
-
View Hint View Answer Discuss in Forum
NA
Correct Option: C
In the call by reference, it will just copy the address of the variable to access it, so it will reduce the memory in accessing it.
- How many can max number of arguments present in function in the c99 compiler?
-
View Hint View Answer Discuss in Forum
NA
Correct Option: A
127
- which of the following is used to terminate the function declaration?
-
View Hint View Answer Discuss in Forum
NA
Correct Option: B
")" is used to terminate the function declaration.
- What are mandatory parts in the function declaration?
-
View Hint View Answer Discuss in Forum
NA
Correct Option: B
In a function, return type and function name are mandatory all else are just used as a choice.