Functions


  1. What is the output of this program?
    #include 
    using namespace std;
    void fun()
    void fun()
    {
    cout<<"Inteview Mania";
    }
    int main()
    {
    fun();
    return 0;
    }











  1. 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.


  1. Which is more effective while calling the functions?











  1. 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.



  1. How many can max number of arguments present in function in the c99 compiler?











  1. View Hint View Answer Discuss in Forum

    NA

    Correct Option: A

    127


  1. which of the following is used to terminate the function declaration?











  1. View Hint View Answer Discuss in Forum

    NA

    Correct Option: B

    ")" is used to terminate the function declaration.



  1. What are mandatory parts in the function declaration?











  1. 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.