int main()
{
int i ,a[i];
i = 0;
a[i] = 10;
cout<< a[i] << endl;
return 0;


}

What will be output of this program?

Answers were Sorted based on User's Feedback



int main() { int i ,a[i]; i = 0; a[i] = 10; cout<< a[i] << endl; return 0; } ..

Answer / ram

main method cannot return any value.

Is This Answer Correct ?    6 Yes 28 No

Post New Answer

More C++ General Interview Questions

how many trys can we write in one class

3 Answers   Cap Gemini,


Do you know what are pure virtual functions?

0 Answers  


Define copy constructor.

0 Answers  


To what does “event-driven” refer?

0 Answers  


what is a reference variable in C++?

0 Answers  






Give 10 points of differences between C & C++.

0 Answers   HCL,


why we cant create array of refrences

4 Answers  


#include<iostream.h> void main() { class x { public: int func(int) { cout<<"cool"; return 1; } } }

1 Answers   Infosys,


What are the differences between the function prototype and the function defi-nition?

0 Answers  


Difference between const char* p and char const* p?

1 Answers  


What are C++ inline functions?

1 Answers  


What is istream and ostream in c++?

0 Answers  


Categories