Program of Printing Reverse of dynamic integer Array in C++



                        Reverse of dynamic integer Array

#include<iostream.h>

int main()

{
   
int i,size;
cout<<"enter size ====";
cin>>size;

int *ptr = new int [size];
cout<<" your Arry is ===="<<endl;
for(i=0;i<=size;i++)   
{
 
cin>>ptr[i];   
       
}
cout<<"your Reverse of Arry is"<<endl;   
for(i=size;i>=0;i--)   
{       
cout<<ptr[i]<<endl;           
}
   
}

          <<<<<<<<<<<<<< ------------------------------------>>>>>>>>>>>>>>>

Share on Google Plus

About Unknown

This is a short description in the author block about the author. You edit it by entering text in the "Biographical Info" field in the user admin panel.
    Blogger Comment
    Facebook Comment

0 comments:

Post a Comment

Powered by Blogger.

Translate

 
 
.