C++/c++

Advertisement


Question
write a programe in c++ to find the reverse contents of an array.
array size is 3.

Answer
int iArray[] = {1,2,3};
int iMaxSize =3;
int  icount = iMaxSize-1;
int  icount1 = 0;
while(i<(Max/2))
{
         int temp = iArray[icount1];
         iArray[icount1] = iArray[icount];
         iArray[icount] = temp;
         icount1++;
         icount--;
    
}

C++

All Answers


Answers by Expert:


Ask Experts

Volunteer


rakshitha

Expertise

Difficult questions related to C .

Experience

C ,vc ,opc ,windows CE, ActiveX

Education/Credentials
Masters in electrical engineering

©2016 About.com. All rights reserved.