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 to allocate memory dynamically for a reference?
On throwing an exception by the animal constructor in p = new animalq, can memory leak occur?
What is a class definition?
What is lazy initialization in c++?
How is new() different from malloc()?
Arrange Doubly linked list in the ascending order of its integral value and replace integer 5 with 7?
Do you know about latest advancements in C++ ?
What is const in c++?
Write a program in c++ to print the numbers from n to n2 except 5 and its multiples
What is double in c++?
Write about the retrieval of n number of objects during the process of delete[]p?
What are the extraction and insertion operators in c++?
Describe linked list using C++ with an example.
What is an operator in c++?
How delete [] is different from delete?