check is number is palindrome in c

Solutions on MaxInterview for check is number is palindrome in c by the best coders in the world

showing results for - "check is number is palindrome in c"
Marta
23 Jun 2019
1#include <stdio.h>
2#include <conio.h>
3
4void main()
5{
6
7    int n,i,r=0;
8    
9    printf("Enter a number: ");
10    scanf("%d",&n);
11    
12    for(i=n;i!=0;i)
13    {
14        r=r*10;
15        r=r+ i%10;
16        i=i/10;
17    }
18    
19    if(r==n)
20        printf("palindrome");
21    else
22        printf("Not palindrome");
23}
Bethany
18 Jul 2018
1// this is for string
2
3#include <stdio.h>
4#include <string.h>
5
6void main()
7{
8  char a[100], b[100];
9
10  printf("Enter a string to check if it's a palindrome: ");
11  gets(a);
12
13  strcpy(b, a);
14
15  if (strcmp(a, b) == 0)
16    printf("\nThe string is palindrome.\n");
17
18  else
19    printf("\nThe string is not palindrome.\n");
20
21  getch();
22}
23
Auguste
16 Mar 2020
1#include <stdio.h>
2#include <conio.h>
3
4int palindrome (int num);
5
6void main()
7{
8    int n, ret;
9    printf("Enter the number: ");
10    scanf("%d",&n);
11
12    ret = palindrome(n);
13
14    if (ret == n)
15        printf("\nPalindrome\n");
16    else
17        printf("\nNot Palindrome\n");
18}
19
20int palindrome(int num)
21{
22    int rem, rev=0;
23
24    while (num!=0)
25    {
26        rem = num % 10;
27        rev = rev * 10 + rem;
28        num /= 10;
29    }
30
31    return rev;
32}
33
queries leading to this page
palindrome program in cwhat is palindrome number in chow to check whether a string is a palindrome or not in ccheck whether a string is palindrome or not in cstring palindrome in c using strrevlongest palindrome in a string in cpalindroem no in cnumber of palindromes based on length n in ca c program to check whether a number is palindrome or not c program to check whether a given number is palindrome using functions check palindrome in cpalindrome in c with charcheck a string is pallindrome or not in cc program for palindrome numberprogram to display palindrome in cpalidrome in ccheck the string is palindrome or not in cstring palindrome using stack in ccheck if given string is palindrome in cprint palindrome in cpalindrome c program codestring palindrome program in c using for loophow to check if number is palindrome in cpalindrome in c stringwrite a c program to check whether a string is palindrome c palindrome checkercheck if given character array is palindrome in cc program for wirting palindromecheck palindrome string in cc check if palindromemore than one palindrome check cpalindrome c stringstring is palindrome or not in cwhy we need to check count 2f2 in palindrome in c programmingpalindrome in c functionc program to check palindrome integerpalindrome number cc program for palindrome using arrayspalindrome number in cpalindrome sting in cpalindrome string program in cstring palindrome in c using pointersstring is palindrome or not c programec program to find given string is palindrome or notc program for palindromeint palindrome in cc palindrome using functionpalindrome string in cc program to check palindrome codechefwrite a programme to check given number is palindrome or not using function in cc program to check whether a given string is palindrome or notprogram to display word palindrome in cprogram in c to check if a number is palindrome or nothow to check if a word is palindrome or not in c phrase palindrome in c functionpalindrome in string in cpalindrome in c using stackstring palindrome program in cpalindrome in c with pointer manuallyc program to print whether the string is palindrome or notpalindrome i n ccheck if a string is palindrome cpalindrome in c program for stringschecking palindrome in cpalindrome meaning in cpalindrome series in cprogram to check palindrome in ccheck string palindrome cpalindrome using strrev in cstack palindrome in cprogram to find the palindrome of a number in cprogram for palindrome in cc program to check palindrome or notpalindrome cpalindrome algorithm in cwrite a program in c to check whether a string is a palindrome or not c programming palindromehow to check the string is palindrome in cprogram to accept string in c and check palindromenumber is palindrome r not in cprogram to check if a string is palindrome or not in cinteger palindrome cfind palindrome string in ccheck whether string is palindrome or not in cwrite a program in c to check whether a number is a palindrome or not palindrome in c with stringpalindrome check in cwrite a program in c to check the number is palindrome or nothow to find palindromes in code cpalindrome means in cprogram for string palindrome in chow to tell if a number is a palindrome in cpalindrome string logic in ccheck if a number is palindrome in cfind a number is palindrome or not in cpalindrome program in c without using string functionsc palindrome programis palindrome check program in cfind whether given string is palindroem or not in cpalidrom number display in cfind palindrome number in ccheck string is palindrome or not in cpalindrome of string in calgorithm wap to check user entered number is palindrome or not in cpalindrome series program in cfonction palindrome en cpalindeom code in creverse a number and check if it is palindrome in c do whilereverse a number and check if it is palindrome in cpalindrom number in c programminghighest value palindrome in cpalindrom in c with pointergiven string palindrome or not in chow to palindrome char in cc program to check a number is palindrome or notcode in c to find given array is palindrome or notpalindrome in array in cpalindrome programe in cpalindrome character program in chow to find the number is prime palindrome or not in cpalindrome program cpalindrome integer in cwrite a programme to check given number is palindrom or not in cpalindrome number program in ccheck a string is palindrome or not in cpalindrome check function in c c program to check whether given string is palindrome or notpalindrome of a string in cpalindrome logic in cpalindrome c functionsequence of palindrome numbers in cpalindrome in c using functionstring palindrome i n cpalindrome in c with pointerc program for palindrome stringfind given number is prime palindrom or not in c programepalindrome c programc program to check palindromecheck for a palindrome string in chow to find if string is a palindrome in c using pointerpalindrome string in c programc check if palindrome string using inbuilt functionchecks whether or not a given unsigned integer is a palindrome in cpalindrome string in cc program to find palindromeinteger palindrome in cpalindrome number in c programmingcheck whether the given string is a palindrome or not in cc program check for palindrome numberpalindrome in cthe given number is palindrome or not palindrome ccheck if a word is a palindrome in cget a string input from user and check palindrome or not in ccheck if number is palindrome in cfind differene of palindrome numbers in cpalindrom in c with pointer manuallyc program to check palindrome codechef solutionpalindrome of a number ccheck if string is a palindrome in cc program to check palindrome stringwrite a c program to enter any number and check whether the number is palindrome or not paliindrome function in cwrite a c program to check if the text is palindrome or not in ccheck palindrome number in cpalindrom number display in ccheck integer palindrome cwrite a function to find out longest palindrome in a given string in cc program to check a string is palindrome or notpalindrome in c programword is palindrome in ccheck palindrome word in cprogram to find string is palindrome or not in cc program palindromec is palindromepalindrome using user defined function in chow to check palindrome in cpalindrome c logicfind given number is prime palindrome or not in c programalgorithm for palindrome number in cc program for palindrome using functioncheck if a number is a palindrome in cwrite a c program to check a number whether it is palindrome or not palindrome check using stack in cpalindrome number prog in cudp program to check palindrome in cprogrma in c to check whether a nuber is palindrome or notc is palindrome functionwrite a c program to check whether a 10 given string is a palindrome or not palindrome checker in ccheck if string is palindrome in chow to find palindrome number in chow to make a palindrome program in c using pointernumber of palindromes in cpalindrome in c using pointerschecking palindrome 28number 29 in c programcheck is number is palindrome in cpalindrome program in c for stringpalindrome explanation in cstring palindrome in c using functionwrite a program in c to check whether the given string is a palindrome or notstring palindrome in cpalindrome code in cc program to print palindrome or notcheck is number is palindrome in c