write program for palindrome
Answer Posted / dude
#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) // This is important step
printf("the no is palindrome");
else
printf("no is not palindrome");
getch();
}
Is This Answer Correct ? | 199 Yes | 137 No |
Post New Answer View All Answers
How can I disable the "echo" feature?
What is setbase c++?
What is an associative container in c++?
What are the uses of c++ in the real world?
What is the history of c++?
Can I create my own functions in c++?
What are the new features that iso/ansi c++ has added to original c++ specifications?
What do you mean by storage classes?
What is & in c++ function?
Explain stack unwinding.
What is the benefit of learning c++?
what is multi-threading in C++?
What are friend classes? What are advantages of using friend classes?
Eplain extern keyword?
Am studying basic c++ programming, have been given the following assignment. Design a linear program to calculate the maximum stress a material can withstand given a force and a diameter of a circle. To find the required area pi should be defined. Have most of the program sorted out but am at a loss as to how to show the calculations required. Can anyone help?