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 in c to input a 5 digit number and print it
in words.

Answers were Sorted based on User's Feedback



Write a program in c to input a 5 digit number and print it in words...

Answer / vignesh1988i

#include<stdioi.h>
void main()
{
int n,count=0,a[20];
scanf("%d",&n);
for(i=0;n>0;i++)
{
a[i]=n%10;
n=n/10;
count++;
}
for(i=0;i<count;i++)
{
switch(a[i])
{
case 1:
printf("one");
break;
case 2:
printf("two");
break;
like this print upto case 0 , (ie) after case 9 ... put
case 0.... and finish the switch and close the loop.......

Is This Answer Correct ?    119 Yes 186 No

Post New Answer

More C Interview Questions

Where is c used?

0 Answers  


How can you increase the allowable number of simultaneously open files?

0 Answers  


What is a program flowchart and explain how does it help in writing a program?

0 Answers  


Write a program to find the biggest number of three numbers in c?

0 Answers  


Explain what is the benefit of using #define to declare a constant?

0 Answers  


Why we use break in c?

0 Answers  


How do I access command-line arguments?

2 Answers   Bosch, Wipro,


enum day = { jan = 1 ,feb=4, april, may} what is the value of may? a)4 b)5 c)6 d)11 e)none of the above

8 Answers   HCL, Wipro,


Which is an example of a structural homology?

0 Answers  


p*=(++q)++*--p when p=q=1 while(q<=6)

0 Answers   KINPOE,


What is string in c language?

0 Answers  


Explain what math functions are available for integers? For floating point?

0 Answers  


Categories