Answer Posted / satrughna sethi
#include<stdio.h>
#include<conio.h>
void main()
{
int i,j;
printf("enter a number");
scanf("%d",&i);
for(int n=1;n<=5;n++)
{
j=i%10;
i=i/10;
printf("%d",j);
}
getch();
}
Is This Answer Correct ? | 5 Yes | 5 No |
Post New Answer View All Answers
Write the program that calculates and prints the average of several integers. Assume that the last value read is sentinel 9999.
What is an arrays?
Where is volatile variable stored?
What are the advantages of c language?
What is preprocessor with example?
Write a factorial program using C.
Why c is a procedural language?
any restrictions have on the number of 'return' statements that may be present in a function. a) no restriction b) only 2 return statements c) only 1 return statements d) none of the above
Why is %d used in c?
Write a c program to build a heap method using Pointer to function and pointer to structure ?
Explain what is the purpose of "extern" keyword in a function declaration?
What is the difference between scanf and fscanf?
Are there any problems with performing mathematical operations on different variable types?
typedef enum { html, java, javascript, perl, cgi } lang;The above statement defines a : a) Union b) User defined type c) Enumerated variable d) none
What is a method in c?