Functions

Q1: What will be the output of the following program?
#include<iostream.h> 
class AptitudeCrack
{
    int K; 
    public:
    void AptitudeFunction(float, int , char);
    void AptitudeFunction(float, char, char);
    
};
int main()
{
    AptitudeCrack objIB;
    objIB.AptitudeFunction(15.09, 'A', char('A' + 'A'));
    return 0;
}
void AptitudeCrack::AptitudeFunction(float, char y, char z)
{
    K = int(z);
    K = int(y);
    K = y + z;
    cout<< 'K = ' << K << endl; 
}

A The program will print the output M = 130.

B The program will print the output M = 195.

C The program will print the output M = -21.

D The program will print the output M = -61.

E The program will report compile time error.

ANS:D - The program will print the output M = -61.

No answer description is available. Let's discuss.



img not found
img

For help Students Orientation
Mcqs Questions

One stop destination for examination, preparation, recruitment, and more. Specially designed online test to solve all your preparation worries. Go wherever you want to and practice whenever you want, using the online test platform.