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
Is c++ an integer?
What is virtual destructor? What is its use?
What is difference between array and vector in c++?
What are the three forms of cin.get() and what are their differences?
Can we distribute function templates and class templates in object libraries?
I was a c++ code and was asked to find out the bug in that. The bug was that he declared an object locally in a function and tried to return the pointer to that object. Since the object is local to the function, it no more exists after returning from the function. The pointer, therefore, is invalid outside.
Which function cannot be overloaded c++?
How is modularity introduced in C++?
Which programming language is best?
What is constructor in C++?
What is the use of "new" operator?
How did c++ start?
Can we use pointers in c++?
How is c++ different from java?
Can you be able to identify between straight- through and cross- over cable wiring? And in what case do you use straight- through and cross-over?