Program to enter the elements of array

#include
#include
main()
{
int a[20],i,n;
clrscr();
cout<>n;
cout<<"n Enter the element:n";
for(i=0;i<n;i++)
{
cout<<"n A["<<i<>a[i];
}
cout<<"nnn";
cout<<"n Entered elemment of array were:";
for(i=0;i<n;i++)
{
cout<<"n A["<<i<<"]="<<a[i];
}
getch();
}

Leave a reply