write a c code "if you give a any decimal number then print that number in english alphabet"?
ex: i/p: 552
o/p: five hundred fifty two ...
#include<stdio.h>
void main()
{
int number,i=0,j,digit;
char * word[1000];
printf("Enter number
");
scanf("%d",&number);
while(number){
digit = number %10;
number = number /10;
switch(digit){
case 0: word[i++] = "zero"; break;
case 1: word[i++] = "one"; break;
case 2: word[i++] = "two"; break;
case 3: word[i++] = "three"; break;
case 4: word[i++] = "four"; break;
case 5: word[i++] = "five"; break;
case 6: word[i++] = "six"; break;
case 7: word[i++] = "seven"; break;
case 8: word[i++] = "eight"; break;
case 9: word[i++] = "nine"; break;
}
}
for(j=i-1;j>=0;j--){
printf("%s ",word[j]);
}
}
| Is This Answer Correct ? | 1 Yes | 5 No |
coding for Fibonacci.?
Take an MxN matrice from user and then sum upper diagonal in a variable and lower diagonal in a separate variables. Print the result
Write a program to produce the following output in c language? 1 1 1 1 2 1 1 3 3 1 1 4 6 4 1
how write a addtion of two single dimensional array using of pointer in c language?
Why flag is used in c?
Is c dynamically typed?
What are the advantages of c language?
What is the difference between the = symbol and == symbol?
What is c method?
stripos — Find position of first occurrence of a case- insensitive string int stripos ( char* haystack, char* needle, int offset ) Returns the numeric position of the first occurrence of needle in the haystack string. Note that the needle may be a string of one or more characters. If needle is not found, stripos() will return -1. The function should not make use of any C library function calls.
Which of the following about the C comments is incorrect ? a.commentscan go over multiple lines b.comments can start any where in the line c.a line can contain comments with out any language statements d.comments can occur within comments
1,4,8,13,21,30,36,45,54,63,73,?,?.
10 Answers AMB, Franklin Templeton,