#include<iostream.h>
#include<conio.h>
int main()
{
int a[100], i, n, max, min;
clrscr();
cout<<"How many elements in the array : ";
cin>>n;
cout<<"Enter the elements : "<<end1;
for(i=1; i<=n-1; i++)
{
cin>>a[i];
}
max = a[0];
min = a[0];
for(i=1; i<=n-1; i++)
{
if ( max < a[i])
max = a[i];
if ( min < a[i])
min = a[i];
}
cout<<end1<<"Maximum element in the array is : "<<max;
cout<<end1<<"Minimum element in the array is : "<<min;
getch();
return 0;
}