A.
#include<iostream.h>
#include<conio.h>
int array[10];
void main()
{
                int i;
                clrscr();
                for(i=0;i<10;i++)
                                {
                                cout<<"Array["<<i<<"]="<<array[i]<<endl;
                                }
                getch();
}

85-a
     B. 
#include<iostream.h>
#include<conio.h>
int array[10];
void main()
{
                int i;
                clrscr();
                for(i=0;i<6;i++)
                                {
                                cout<<"Enter Value for Array["<<i<<"]=";
                                cin>>array[i];
                                }
                cout<<endl;
                for(i=0;i<10;i++)
                                {
                                cout<<"Array["<<i<<"]="<<array[i]<<endl;
                                }
                getch();
}

85-b
Advertisements