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 reverse of a number using for
loop?

Answer Posted / ganagdhara c

#include<stdio.h>
#include<conio.h>
void main()
{
long int num,i;
int d;
clrscr();
printf("\n enter number");
scanf("%ld",&num);
printf("\n the reverse of number %ld is ",num);
for(i=0;num>0;i++)
{
d=num%10;
num=num/10;
printf("%d",d);
}
getch();
}

Is This Answer Correct ?    22 Yes 17 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

regarding pointers concept

1989


What is use of bit field?

1254


Here is a good puzzle: how do you write a program which produces its own source code as output?

1057


What are different storage class specifiers in c?

1058


Is stack a keyword in c?

1046


i have to apply for rbi before that i need to know the the syllabus for the entrance questions. whethet it may be aps or techinical

2291


while loop contains parts a) initialisation, evalution of an expression,increment /decrement b) initialisation, increment/decrement c) condition evalution d) none of the above

1201


Why is this loop always executing once?

1008


"%u" unsigned integer print the a) address of variable b) value of variable c) name of a variable d) none of the above

992


What are identifiers c?

1030


Explain b+ tree?

1019


What's the right way to use errno?

1101


which of the following is allowed in a "C" arithematic instruction a) [] b) {} c) () d) none of the above

1675


Write the program with at least two functions to solve the following problem. The members of the board of a small university are considering voting for a pay increase for their 10 faculty members. They are considering a pay increase of 8%. Write a program that will prompt for and accept the current salary for each of the faculty members, then calculate and display their individual pay increases. At the end of the program, print the total faculty payroll before and after the pay increase, and the total pay increase involved.

3069


what do you mean by enumeration constant?

971