Predict the output of the given C++ program:
What are the things that are inherited from the base class?
What is the default value of elements in a static array that is not initialized?
What can pointers to members be used to refer to?
What is the value of the postfix expression 6 3 2 4 + – *:
What is the output of the following C program?
int main()
{
int Y = 10;
if (Y++ > 9 && Y++ != 10 && Y++ > 10)
printf("%d", Y);
else
printf("%d", Y);
}
Which one of the following options is correct about the statement given below? The compiler checks the type of reference in the object and not the type of object ?
What is the error, if any, in the following C statement?
signed int *p = (int*)malloc(sizeof(unsigned int));
What will be the output of the following C++ code?
#include <iostream>
#include <iterator>
#include <vector>
using namespace std;
int main()
{
vector<int> ar = { 1, 2, 3, 4, 5 };
vector<int>::iterator ptr = ar.begin();
ptr = next(ptr, 3);
cout << *ptr << endl;
return 0;
}