Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

write a program to display the array elements in reverse
order in c language

Answer Posted / tej

#include<stdio.h>
#include<conio.h>
void main()
{
int a[],n;
printf("enter array size");
scanf("%d",&n);
printf("enter elements of an array");
for(i=0;i<n;i++)
{
scanf("%d",a[i]);
}
for(i=1;i<=n;i++)
{
printf("%d",a[n-i]);
}
getch();
}

Is This Answer Correct ?    7 Yes 6 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

the portion of a computer program within which the definition of the variable remains unchanged a) mode b) module c) scope d) none

1060


What is the difference between formatted&unformatted i/o functions?

1060


What is int main () in c?

1091


What are data structures in c and how to use them?

1173


what is associativity explain what is the precidence for * and & , * and ++ how the folloing declaration work 1) *&p; 2) *p++;

2439


What is assignment operator?

1059


What is the modulus operator?

1214


How can a string be converted to a number?

1023


Why is it usually a bad idea to use gets()? Suggest a workaround.

1789


Explain what is meant by 'bit masking'?

1201


What are the types of operators in c?

1066


How can you avoid including a header more than once?

986


Explain how can I read and write comma-delimited text?

1169


What is graph in c?

1059


What is structure of c program?

1168