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...

HOW TO FIND OUT THE RREVERS OF A GIVEN DIGIT NUMBER IF IT
IS INPUT THROUGH THE KEYBORD BY USING C LANGUAGE

Answer Posted / prof.gagandeep jagdev

#include<stdio.h>
#include<conio.h>
long int num,result=0,i;
void main()
{
clrscr();
printf("\nenter the number to be reversed=");
scanf("%ld",&num);
while(num>0)
{
i=num%10;
num=num/10;
result=result*10+i;
}
printf("\nReversed number is=%ld",result);
getch();
}

Is This Answer Correct ?    4 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is structure packing in c?

1027


Explain the difference between null pointer and void pointer.

1034


How do you view the path?

1078


The file stdio.h, what does it contain?

1119


Why we write conio h in c?

967


What is scope rule of function in c?

1031


why we wont use '&' sing in aceesing the string using scanf

2315


pierrot's divisor program using c or c++ code

2172


How are Structure passing and returning implemented by the complier?

1109


any C program contains only one function, it must be a) void () b) main () c) message () d) abc ()

1080


What is C language ?

1904


What is the difference between ā€˜g’ and ā€œgā€ in C?

3914


What is bss in c?

1048


Write a factorial program using C.

1021


what is the significance of static storage class specifier?

2187