write a program to display reverse of a number using for
loop?
Answer Posted / k.ashok kumar
BETTER CODE:
#include<stdio.h>
#include<conio.h>
void main()
{
int a;
clrscr();
printf("\n Enter a number : ");
scanf("%d",&a);
printf("\n Reverse number of %d is : ",a);
while(a)
{
printf("%d",a%10);
a/=10;
}
getch();
}
| Is This Answer Correct ? | 6 Yes | 8 No |
Post New Answer View All Answers
Explain what is the most efficient way to store flag values?
What is volatile c?
In C language, a variable name cannot contain?
What is f'n in math?
What is hashing in c language?
Who invented b language?
What are the benefits of c language?
Is main a keyword in c?
What is #pragma statements?
Why #include is used in c language?
What is openmp in c?
Where is volatile variable stored?
What is string concatenation in c?
Can the size of an array be declared at runtime?
Is there sort function in c?