write a c program to accept a given integer value and print
its value in words
Answer Posted / sheikh rasel
#include<stdio.h>
int main()
{
int n;
clrscr();
printf("\nenter a integer number::");
scanf("%d",&n);
switch(n)
{
case:1
printf("\nOne");
break;
case:2
printf("\nTwo");
break;
case:3
printf("\nThree");
break;
case:4
printf("\nFour");
brak;
case:5
printf("\nFive");
break;
case:6
printf("\nSix");
break;
case:7
printf("\nSeven");
break;
case:8
printf("\nEight");
break;
case:9
printf("\nNine");
break;
default:
printf("\nSorry");
}
getch();
}
| Is This Answer Correct ? | 17 Yes | 39 No |
Post New Answer View All Answers
What is calloc() function?
What is a void pointer in c?
count = 0; for (i = 1;i < = 10; i++);count = count + i; Value of count after execution of the above statements will be a) 0 b) 11 c) 55 d) array
How do you list a file’s date and time?
what are the facialities provided by you after the selection of the student.
the number of measuring units from a arbitrary starting point in a record area or control block to some other point a) branching b) recording pointer c) none d) offset
What is #pragma statements?
What is the scope of global variable in c?
is it possible to create your own header files?
What are file streams?
What are # preprocessor operator in c?
What are the types of unary operators?
2) Write a program that will help Air Traffic Control for an airport to view the sequence of flights ready for take-off. The airport can accommodate 10 flights waiting for take-off at any point in time. Each flight has a unique 3 digit numeric identifier. Each time a flight takes-off, Air Traffic Control adds a flight to the waitlist. Each time a flight is added to the waitlist, the list of flights waiting to take-off must be displayed. When a flight is cleared for take-off, Air Traffic Control removes the flight from the waitlist. Each time a flight takes-off, the list of flights waiting to take-off must be displayed. Sequence of take-off is the sequence of addition to the waitlist
Here is a neat trick for checking whether two strings are equal
Explain what is meant by high-order and low-order bytes?