palindrome for strings and numbers----Can anybody do the
prog?
Answer Posted / arup bhattacharya
#include<stdio.h>
#include<conio.h>
void main()
{
int n,r,temp;
int s=0;
clrscr();
printf("enter the number");
scanf("%d",&n);
temp=n;
while(temp>0)
{
r=temp%10;
s=s*10+r;
temp=temp/10;
}
if(n==temp)
printf(number is pallindrome");
else
printf("not pallindrome");
getch();
}
| Is This Answer Correct ? | 9 Yes | 8 No |
Post New Answer View All Answers
which of the following is allowed in a "C" arithematic instruction a) [] b) {} c) () d) none of the above
What is the difference between a function and a method in c?
What are the scope of static variables?
In c programming typeing to occupy the variables in memory space. if not useing the variable the memory space is wasted.ok, how to avoid the situation..? (the variable is used & notused)
What is a stream?
What’s the special use of UNIONS?
Explain what is the advantage of a random access file?
How can you be sure that a program follows the ANSI C standard?
How do you determine whether to use a stream function or a low-level function?
What is assignment operator?
Explain b+ tree?
How do I get a null pointer in my programs?
Explain what is #line used for?
What is a const pointer?
Why are some ANSI/ISO Standard library routines showing up as undefined, even though I've got an ANSI compiler?