can output 5 students using one dimensional array
Answer Posted / hari haran
#include<iostream.h>
void main()
{
int a[5];
for(int i=0;i<n;i++)
{
cin>>a[i];
}
for(int i=0;i<n;i++)
{
cout<<"
"<<a[i];
}
}
Is This Answer Correct ? | 3 Yes | 0 No |
Post New Answer View All Answers
What does new do in c++?
Why do we use structure in c++?
How does com provide language transparency?
What are the three forms of cin.get() and what are their differences?
Show the application of a dynamic array with the help of an example.
What is the difference between method overloading and method overriding in c++?
What do you mean by persistent and non persistent objects?
How would you implement a substr() function that extracts a sub string from a given string?
How is c++ different from java?
What is the difference between passing by reference and passing a reference?
What is auto type c++?
Can we inherit constructor in c++?
What is token c++?
What is void pointer in c++ with example?
What is an arraylist c++?