to find out the reverse digit of a given number

Answer Posted / vaibhav

#include<stdio.h>
#include<conio.h>
void main()
{
int no, t;
clrscr();
printf("\nenter the no.");
scanf("%d",&no);
while(no!=0)
{
t=no%10;
no=no/10;
printf("%d",t);
}
getch();
}

Is This Answer Correct ?    23 Yes 9 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Write a program to reverse a string.

642


Explain #pragma statements.

604


Explain how do you list files in a directory?

618


What is the g value paradox?

645


What is a floating point in c?

604






the statement while(i) puts the entire logic in loop. this loop is called a) indefinite loop b) definite loop c) loop syntax wrong d) none of the above

606


Multiply an Integer Number by 2 Without Using Multiplication Operator

321


How can you restore a redirected standard stream?

610


Can true be a variable name in c?

559


#define PRINT(int) printf("int = %d ",int) main() {< BR> intx,y,z; x=03;y=02;z=01; PRINT(x^x); z<<=3;PRINT(x); y>>=3;PRINT(y); }

720


write a c program to do the following: a) To find the area of a triangle. b) To convert the temperature from Fahrenheit to Celsius. c) To convert the time in hours : minutes : seconds to seconds.

1518


What is the correct code to have following output in c using nested for loop?

613


Synonymous with pointer array a) character array b) ragged array c) multiple array d) none

616


a construct the"else" part of "if" statement contains anoth "if else" statement is called a) if-else b) else-if-else c) if-else-if-else d) chain if/if-else-if

704


How can you convert integers to binary or hexadecimal?

616