C++ Pointers & Functions Question: Download Questions PDF
Output of this program?
#include <iostream>
using namespace std;
int main()
{
int i;
char *arr[] = {"C", "C++", "Java", "VBA"};
char *(*ptr)[4] = &arr;
cout << ++(*ptr)[2];
return 0;
}
a) ava
b) java
c) c++
d) compile time error
Answer:
a) ava
Download C++ Pointers & Functions Interview Questions And Answers
PDF