write program for palindrome
Answer Posted / jamai partha
#include<stdio.h>
#include<conio.h>
void main()
{
int n,s=0,m;
clrscr();
printf("enter any no");
scanf("%d",&n);
m=n;
while(n>0)
{
r=n%10;
s=s*10+r;
n=n/10;
}
if(s==n)
printf("the no is palindrome");
else
printf("no is not palindrome");
getch();
}
Is This Answer Correct ? | 0 Yes | 1 No |
Post New Answer View All Answers
Which programming language's unsatisfactory performance led to the discovery of c++?
What is a Default constructor?
What is a driver program?
How to demonstrate the use of a variable?
Which bit wise operator is suitable for turning off a particular bit in a number?
What is data hiding c++?
What character terminates all character array strings a) b) . c) END
What is prototype for that c string function?
What is class in c++ with example?
What is polymorphism and its type in c++?
Difference between a homogeneous and a heterogeneous container
Arrange Doubly linked list in the ascending order of its integral value and replace integer 5 with 7?
What are the 4 types of library?
What are the restrictions apply to constructors and destructors?
How can you quickly find the number of elements stored in a static array?