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

simple c program for 12345 convert 54321 with out using string

Answer Posted / sreenivas

#include<stdio.h>
main()
{
long n=12345,r=0;
while(n)
{
r=r*10+n%10;
n=n/10;
}
printf("%ld",r);
}

Is This Answer Correct ?    13 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Explain what does the function toupper() do?

1004


What are the advantages of using Unions?

1065


What is realloc in c?

1014


What is advantage of pointer in c?

1121


Create a structure to specify data on students as given below: Roll number, Name, Department, Course, and Year of joining. Assume that there are not more than 450 students in the collage. (a) Write a function to print the names of all students who joined in the last 3 years. (b) Write a function to print the data of a student whose roll numbers are divisible by 4.

1051


What is c variable?

992


How can type-insensitive macros be created?

1126


What is FIFO?

1538


In a byte, what is the maximum decimal number that you can accommodate?

1067


List some of the static data structures in C?

1154


What is the use of getchar functions?

1125


How will you declare an array of three function pointers where each function receives two ints and returns a float?

1289


Why flag is used in c?

1065


4-Take two sets of 5 numbers from user in two arrays. Sort array 1 in ascending and array 2 in descending order. Perform sorting by passing array to a function mySort(array, sortingOrder). Then multiply both the arrays returned from function, using metric multiplication technique in main. Print result in metric format.

2135


Can you explain what keyboard debouncing is, and where and why we us it? please give some examples

2143