int main()
{
int i ,a[i];
i = 0;
a[i] = 10;
cout<< a[i] << endl;
return 0;
}
What will be output of this program?
Answer Posted / ramesh kumar
in array we can must enter size integer...
not as variable type like i
thats why it gives an error
| Is This Answer Correct ? | 9 Yes | 2 No |
Post New Answer View All Answers
How can you link a c++ program to c functions?
What does new do in c++?
How is modularity introduced in C++?
What does std mean in c++?
Does c++ have string data type?
What header file is needed for exit(); a) stdlib.h b) conio.h c) dos.h
What is buffer and example?
Can we define a constructor as virtual in c++?
Why is "using namespace std;" considered bad practice?
Can I have a reference as a data member of a class? If yes, then how do I initialise it?
Explain virtual destructor?
What is the use of string in c++?
Describe new operator?
How to get the current position of the file pointer?
Why is main an int?