CSE MCQs :: C++ - MCQs
- Which of the following correctly declares an array?
- What is a array?
- Which of the following accesses the seventh element stored in array?
- Which of the following gives the memory address of the first element in array?
-
What is the output of this program?
#include < stdio.h >
using namespace std;
int main()
{
char str[5] = "ABC";
cout << str[3];
cout << str;
return 0;
}
-
What is the output of this program?
#include < stdio.h >
using namespace std;
int main()
{
int array[] = {10, 20, 30};
cout << -2[array];
return 0;
}