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

If input is 123 then how to print 100 and 20 and 3 seperately?

Answer Posted / charusheela

#include<stdio.h>
#include<conio.h>
void main(){
int num=123,r,i=1;
clrscr();
while(num)
{
r=num%10;
printf("%d\n",r*i);
i*=10;
num/=10;
}
getch();
}

Is This Answer Correct ?    2 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Explain two-dimensional array.

1134


What is structure packing in c?

1140


Why do we need arrays in c?

1215


What is a newline escape sequence?

1162


Write program to remove duplicate in an array?

1132


What could possibly be the problem if a valid function name such as tolower() is being reported by the C compiler as undefined?

1330


What is the difference between %d and %i?

1148


What are header files in c programming?

1182


Is c call by value?

1080


Write a function which takes as parameters one regular expression(only ? and * are the special characters) and a string and returns whether the string matched the regular expression.

1158


Explain how can I pad a string to a known length?

1251


List the difference between a "copy constructor" and a "assignment operator"?

1068


Write a programme using structure that create a record of students. The user allow to add a record and delete a record and also show the records in ascending order.

2153


write a c program to find the sum of five entered numbers using an array named number

2208


What is a lvalue

1149