Follow us on:

Palindrome in c

palindrome in c g. This palindrome program is implemented using while loop and the input is taken by the user to check whether the number entered by the user is palindrome or not. Here we have a Program for Palindrome in C++: Program for Palindrome in C++. C palindrome string program. We hope that this post helped you develop a better understanding of how to check string is palindrome or not in C++. Given a string, write a c function to check if it is palindrome or not. You don't "use" palindromes in C++ as such, but there is a call again the same function with increasing base function palindrome(str + 1) if condition 3 is false again check if variable i and c are equal (c == i) if both are equal then string is palindrome so return 1. 5' to 3') on one strand matches the sequence reading in the opposite direction (e. a) Create two dummy linked lists (fast and slow). What is a palindrome? A palindrome is nothing but a text or string which when read forward or backward is read the same. tech/2021/04/palindrome-program-in-c. Palindrome number algorithm. ", Number); return 0; } A palindrome number is one that remains the same on reversal. or Write a program to find out all palindrome numbers present within a given range in C. All input comes out as not being a palindrome. In the example above you would have 5 possible subarrays with the length of the desired palindrome: [3,8,4] [8,4,6] [4,6,4] [6,4,0] [4,0,1] As you can see the 3rd one is a valid palindrome for this example. If all the characters in the input string match correctly, then it is a palindrome string, otherwise not. Write a program in C to Check whether a given string is Palindrome or not. b) Slow and fast are copies of given linked lists. If both of them have same sequence of characters i. Software to check weather the word ,sentence,number are same when read from backward and forward eg Racecar,malayalam etc uses array ,first index and last index this is the one and only GUI version of palindrome available on-line checking word and sentences Like, Comments, Share and SUBSCRIBE Palindrome Number: It is a number which remains same even when the number is reversed. Then, we can scan the first half of the Palindrome to see if it is all ‘a’. Valid Palindrome. Let’ dive into an example to check whether a given input is a palindrome or not. Madam In Eden, I’m Adam is one of the best examples of palindrome words that sounds the same after reversing. In this program we will read an integer number and check it is Palindrome Number or Not. This is where palindrome makes things interesting they act as mirrors. If you want to know the detailed solution of the discuss /* C Program to check string is palindrome or not using pointers */ #include <stdio. e. Once that is done, you need to check if that string is a palindrome. Check Palindrome Number or Not To check whether a number given by user is a palindrome number or not in C++, first receive the number, initialize its value to a variable say temp and reverse the value of temp. Palindrome:-An integer is a palindrome number if the reverse of that number is equal to the original number. Introduction to Palindrome in C Program. ", t); else printf("%d is not a palindrome number. I'm trying to do a recursive function with C to check if a word is a palindrome or not (read in both ways). We are using while loop and else if statement in C Program. If the string is a Palindrome, then the function will return ‘true’ otherwise it will return false. ", Number); else printf("%d is not the Palindrome Number. Because, we need to write a program to check palindrome using pointers in c programming. The instructions assume the user is new to computer programming. After reversing, check whether the original number is equal to temp or not. Now for the diagonal ones, you need to start from a point at the edge and then move forward diagonally (+[1][1]) for going to the bottom right until you reach the end. In that number is a palindrome. C Example. In this tutorial we will learn how to find palindrome numbers in a given range. Program code to find whether a Number is Palindrome or Not: In this palindrome program, within the function declaration,. #include <stdio. h> void main() { int a, b, c, s = 0; clrscr(); printf("Enter a number:\t"); scanf("%d", &a); c = a; // the number is reversed inside the while loop. I've got the program to reverse the input, but I'm having trouble getting the strings to compare. h> #include<conio. Use the std::equal Method to Check for String Palindrome in C++ Use Custom Function to Check for String Palindrome in C++ This article will explain several methods of how to check if a string is a palindrome in C++. C++ Program to Print String C++ Program to Find ASCII Value of a Character C++ Functions with No Arguments and No return value C++ Program to Creating a Pyramid C++ Program to Demonstrate Use of Ternary Operator C++ Program to Check Whether Given String is a Palindrome Related Program: C Program to check whether the number is a Palindrome How it works #. C Programming language tutorial, Sample C programs, C++ Programs, Java Program, Interview Questions, C graphics programming, Data Structures, Binary Tree, Linked List, Stack, Queue, Header files, Design Patterns in Java, Triangle and Star pyramid pattern, Palindrome anagram Fibonacci programs, C puzzles. Tags for Palindrome without using string functions in C. C++: Palindrome program in C#. From Wikipedia, A palindrome is a word, number, phrase, or other sequence of characters which reads the same backward as forward, such as madam, racecar. 5' to 3') on the complementary strand . Live - 100s of Live Shows focused on learning and professional growth Why Join Become a member Login C# Program for Palindrome - A palindrome number is a number that is same after reverse. A palindrome string is a string that is equal from both sides. This is one of the easiest programs to find Palindrome program using while loop. Recommended: Please solve it on “ PRACTICE ” first, before moving on to the solution. ", t); } Copy. Ex:-A number is 123321 . Palindrome numbers are numbers that look same if reversed. NET inbuilt function SequenceEqual () and Reverse (). C program to check if a string or a number is palindrome or not. are the palindrome numbers. Palindrome program using while loop in C++. C program example for palindrome: What is palindrome? When a number or word or a phrase or a sequence of characters which resembles the same while reading them from backward are called palindrome. There are even palindrome numbers which are numbers which are the same when read forward and backward. C++ Program to Check Whether a Number or String is a Palindrome or not (5 Ways) by Amit Rawat · Published May 17, 2019 · Updated May 31, 2019 Palindrome Number: It is a number which remains same even when the number is reversed. To check if a number is a palindrome or not, we reverse it and compare it with the original number. Store it in some variable say num. Example 1: Input: palindrome = "abccba" Output: "aaccba" Explanation: There are many ways to make "abccba" not a palindrome, such as "zbccba", "aaccba", and "abacba". Palindrome Number: It is a number which remains same even when the number is reversed. The following table demonstrates what happens at each iteration of the while loop, assuming word = radar. If a number remains same, even if we reverse its digits then the number is known as palindrome number. This C++ palindrome number example allows the user to enter the minimum and maximum values. Palindrome String Program in C. 18, Jun 17. Write a C program to find out all palindrome numbers present within a given range. tech/2021/04/palindrome-program-in-c. To do this first, run three nested loops, the outer two loops pick all substrings one by one by fixing the corner characters, the inner loop checks whether the picked substring is palindrome or not. We will also find the palindrome number in the given range. TRY CSharp. A Palindrome is a result that gives the same value after reversing the original value. Basic C programming, If else, While loop. Get the number from user; Hold the number in temporary variable; Reverse the number; Compare the temporary number with reversed number Palindrome in C. A string is said to be palindrome if reverse of the string is same as string. This program takes an integer from user and that integer is reversed. Check if a string is palindrome in C using pointers. Palindrome means reversing a given object that gives the same result as original. What is Palindrome number? Palindrome number is such number which when reversed is equal to the original number. Top 10+ C Programs Fibonacci Series Prime Number Palindrome Number Factorial Armstrong Number Sum of digits Reverse Number Swap Number Print "Hello" without ; Assembly code in C C program without main Matrix Multiplication Decimal to Binary Number in Characters Alphabet Triangle Number Triangle Fibonacci Triangle FACE Prep is India's best platform to prepare for your dream tech job. else return 0; variable i and c are declared as static because we have to track these value across multiple palindrome() function. If you miss this statement, then after completing the first line, it terminates. Expected Output Enter any string nayan The string nayan is a palindrome. C program to check whether number is Palindrome or Not - C program for Palindrome - C programming Example. It's the first time I use this kind of function, but I have a problem, I don't know why it C Program to Check Palindrome. Online C Stack programs for computer science and information technology students pursuing BE, BTech, MCA, MTech, MCS, MSc, BCA, BSc. A Palindrome number is a number that remains the same when its digits are reversed. C Program to Check the Given String is Palindrome Example 1 Program to check if an Array is Palindrome or not using STL in C++. Lets have a look at the given code: Palindrome in C Program. integer_reverse (Number // 10) – it helps to call the function Recursively with the updated value. Palindrome meaning in C A palindrome string is a string that reads the same backward as forward and can be of odd or even length. Input a number from user. Like 16461, for example: we take 121 and reverse it, after revers it is same as original. A palindrome number is one that remains the same on reversal. This will make a non Palindrome with the smallest lexicographically order. Check Armstrong Number. The first run is to count the occurences of each character and store the frequencies in a hash map e. Then, when a character appears Write a program in C to check whether an integer is Armstrong number or not. Method 1: Brute Force. unordered_map in C++. Example. Next, it prints the palindrome numbers between min and max values. Palindrome number program in C. The main () function calls the checkpalindrome (char *s) by passing the string as an argument. Let us see how to write a C Program to Check the Given String is Palindrome using Built-in functions, and without using built-in functions. This program works as follows :- at first we copy the entered string into a new string, and then we reverse the new string and then compares it with original string. C program to find out the palindrome number in a range : In this C programming tutorial, we will learn how to find out all palindrome numbers in a range. Else it isn't. Following is a program to check whether a string is palindrome or not. In C++ Program to Check if a Given String is a Palindrome. For example, Numbers like 0,1,2,11,44,121,222,242,345543 are called as Palindrome Numbers. Program code to find whether a Number is Palindrome or Not: first character (c) is not equal to last character (r) In other words, you can say that, if the reverse of a string is equal to its original, then that string can be called as a palindrome string. Before that, first, we will see what is the meaning of Palindrome. g: MADAM, NAN, 12321, ANNA etc. 3) For loop iterates from i=0 to i<length of the string/2, If the element at s [i] is equal to element at s [n-i-1] then increase the c value. Checking palindrome number is a popular tutorial of C programming language to learn the basic looping techniques. Algorithm. Palindrome number in c: A palindrome number is a number that is same after reverse. For example: 121, 12321, 1001 etc. Write a program in C to check whether a number is palindrome or not using recursive method. S. C Programming Mathematics: Exercise-23 with Solution. Find code solutions to questions for lab practicals and assignments. For example, the numbers such as 121, 232, 12344321, 34543, 98789, etc. As the palindrome numbers carry great significance in mathematics, physics and engineering, the study of palindrome number is considered essential in all science related faculties. How to check if a given number is Palindrome or not? Algorithm to check Palindrome Number in C#: C++ while and do while Loop. A palindrome is a word or phrase or a sequence of characters that reads the same either read from backward or as in forwards e. Malayalam, Madam, etc. Of all the ways, "aaccba" is the lexicographically smallest. Write a program in C to print the fibonacci series using recursive method. For example, madam, radar, level, mom are palindrome strings. Look at the below program carefully, which takes the input from the user and checks whether it is a palindrome or not. To understand this example, you should have the knowledge of the following C++ programming topics: . Approach: The simple approach is to check each substring whether the substring is a palindrome or not. Palindrome in C: Any number could be Palindrome in C if it remained the same when we reversed it. C Program to Check whether the Given String is a Palindrome Palindrome is a string, which when read in both forward and backward way is same. h> #include<string. It can be of odd or even length. Palindrome in C Hey I am writing a program there is supposed to check wether a inputted word is a palindrom (word there is the same forwards and backwards, like madam or dad) or not. c or even simpler, just place the definition for palindrome above that for main and you won't need any forward declaration. That is called a palindrome number. Some examples are 8, 121, 212, 12321, -454. Now that you understood the concept, let’s simply dive into a program to check palindrome in Python. A palindrome has the same letters on both ends of the string. : I am a newbie and learning C. 11, Mar 19. Palindrome : an integer or a string that reads the same backwards as forwards. A function is a block of code that performs a specific task. Suppose we have a string s. #include<stdio. Code link: https://www. A Palindrome number is a number that is going to be the same after reversing the digits of that number. A palindrome is a string that its reverse is the same string. class Program { /// <summary> /// Determines whether the string is a palindrome. Below are the algorithm and program for same. Write a program in C to add two integer without using arithmetic + operator. C++ Program to Check Whether a Number is Palindrome or Not; Check if an array is read-only or not in C#; Queries to check if substring[L…R] is palindrome or not in C++ Program; Check if the value entered is palindrome or not using C language; Program to check if an array is sorted or not (Iterative and Recursive) in C C Program to check if an Array is Palindrome or not; Program to check if an Array is Palindrome or not using STL in C++; C# program to check if a string is palindrome or not; Python program to check if a string is palindrome or not; Check if the value entered is palindrome or not using C language; Write a C# program to check if a number is A Palindrome is a sequence that if reversed looks identical to the original sequence Eg : abba, level, 999 etc. "ABCDCBA" or even "ABBA". Get App. C Example. g. C program for palindrome or palindrome in c programming: palindrome program in c language, c code to check if a string is a palindrome or not and for palindrome number. C Programming Operators. g. If you read number “123321” from reverse order, it is same as “123321”. h> int is_palindrome(char*); void copy_string(char*, char*); void reverse_string(char*); int string_length(char*); int compare_string(char*, char*); int main() { char string[100]; int result; printf("Enter any string :: "); scanf("%s",string); result = is_palindrome(string); if ( result == 1 ) printf(" [ %s ] is a palindrome string. Greedy Algorithm to Compute Longest Palindrome. C palindrome string program. C if else Statement. getline(string,50); len = strlen(string); for(i=0, x=len-1;i<=len/2;i++, x--) { if(string[i]!=string[x]) { flag=1; break; } } if(flag==0) { cout<<" String is palindrome"; } else { cout<<" String is not a palindrome"; } } A: Palindrome, B: Loop, C: Stem A palindromic sequence is a nucleic acid sequence in a double-stranded DNA or RNA molecule wherein reading in a certain direction (e. Palindrome program in C. ", string C++ program to check if a string is palindrome. For example: 121 or Oppo etc. g. In this article, we are going to see how to see what is palindrome in C, How it works in the C program, how to identify if the given number or string is a palindrome or not. In this post, we will learn how to find if a string is palindrome or not in C++. C Program to Check Palindrome number In today's video, we will discuss how to check if a given number or a string is a palindrome or not. C while and do while Loop. C# Palindrome Method: Words and SentencesDevelop an algorithm that determines if a string is a palindrome. Otherwise, we change the first non ‘a’ character to ‘a’. Count Number of Digits in an Integer. In C programs to check if the input number is palindrome or not. Given a string s, determine if it is a palindrome, considering only alphanumeric characters and ignoring cases. ex: kayak Let’s look at the below example, to find out if the string is palindromic or not. One longest palindrome that can be built is “dccaccd”, whose length is 7. Palindrome in C Hello! Was just wondering if there's a C program which can take from the user a number and it checks if its a palindrome or not I know that we %10 This program works as follows :- at first we copy the entered string into a new string, and then we reverse the new string and then compares it with original string. A string could be Palindrome string in C if it remained the same when we reversed it. It will be very difficult to use pointer with numbers. Python program to check if a string is palindrome or not. For example, “abba” is palindrome, but “abbc” is not palindrome. Find the possible mistakes in the following Shamil’s Flow Table of the program to show whether a number is a palindrome or not using a do-while loop? C Program to Check if a Given String is Palindrome; Check if a given string is a rotation of a palindrome; C++ Program to print all palindromes in a given range; Check if characters of a given string can be rearranged to form a palindrome; Dynamic Programming | Set 28 (Minimum insertions to form a palindrome) Longest Palindromic Substring | Set 2 C++ Program to Print Palindrome Numbers from 1 to 100. In this series of C programming in hindi tutorial videos, I have explained you everything you need to know about C language. C Example. Also read : C Program to Find the Sum of Cubes of Elements in an Array. 123 = 321 So, 123 is not a palindrome number. C Program to check entered string is palindrome using stack. In the last tutorial we have learnt how to check if a number is palindrome or not. Can someone guide me? P. C Programming language tutorial, Sample C programs, C++ Programs, Java Program, Interview Questions, C graphics programming, Data Structures, Binary Tree, Linked List, Stack, Queue, Header files, Design Patterns in Java, Triangle and Star pyramid pattern, Palindrome anagram Fibonacci programs, C puzzles. The Logic Behind Palindrome In C# Simple logic used here traverses the serried of input backward and forward, and the given number or a string is the same as the initial than that corresponding output called a palindrome. For example 12321 is a palindrome number because it remains same if we reverse its digits. h> int main() {int n, reversedInteger = 0, remainder, originalInteger; printf("Enter an integer: "); scanf("%d", &n); originalInteger = n; // reversed integer is stored in variable while( n!=0 ) {remainder = n%10; reversedInteger = reversedInteger*10 + remainder; n /= 10;} Palindrome in C Hey I am writing a program there is supposed to check wether a inputted word is a palindrom (word there is the same forwards and backwards, like madam or dad) or not. Logic to check palindrome number using recursion I have discussed before on how to find all palindrome numbers in C++ in this post. Code link: https://www. Hence the function must return an integer. It contains a program to reverse a string and to check whether a Entered string is palindrome or not. For example - 121, 34543, 343, 131, 48984 are the palindrome numbers. Check Whether a Number is Palindrome or Not. Steps to write program Palindrome is a word that reads the same forward or backward. Explanation : Reversing "ABCCAB" results in "BACCBA" and both are not same so it is a non - palindromic string. A palindrome number is a number that is equal to its reverse. Considering the above points function declaration to check palindrome number is - int isPalindrome (int num);. To check if a number is a palindrome or not, we reverse it and compare it with the original number. This C program checks a given string whether it is a palindrome or not. The palindrome number is based on Reverse of a number. My OS: Ubuntu 15. Use const where practical A palindrome is just a string that reads the same backwards as forwards, e. Enter any string vijay The string vijay is not a palindrome. We have to check whether the given string is a palindrome or not. #include<iostream. It can contain any type of characters. In this article, we are going to see how to test the Palindrome Program in C++ with the help of some examples. The Unlike Java, C does not force you into proliferating bunches of files for every program. Program code to find whether a Number is Palindrome or Not: Palindrome in C #include <stdio. Introduction to Palindrome in C++ A palindrome is a number, sequence or a word that reads the same backward as forwards. If both are the same, it's a palindrome otherwise not. The entered string is copied to a new string, and then we compare the first letter with the last letter of string and second letter with second last letter and so on till the end of the string. The declaration can either be in main. C Code: #include <stdio. Below is a simple C program to find whether the user input number is a palindrome or not using recursion: Palindrome program in C++ A palindrome number is a number that is same after reverse. If they are all matched the string is a palindrome otherwise it is not,as simple as that but my output shows 123;mom; and every nonsense, a palindrome ("even the word 'nonsense' :D). Time Complexity : O(n) Step 1 : Get the middle of the given linked list. The logic behind palindrome is as simple as it sounds. I hope you are enjoying this C i These instructions will guide you in writing a computer program in C++ that will tell the user if a particular word is a palindrome (a word that reads the same backward as it does forward, such as “madam”). Example:-5225 = 5225 So, 5225 is a palindrome number. Step by step descriptive logic to check palindrome number. h> int main() { int Number, Temp, Reminder, Reverse = 0; printf(" Please Enter any number to Check for Palindrome "); scanf("%d", &Number); for(Temp = Number; Temp > 0; Temp = Temp /10 ) { Reminder = Temp %10; Reverse = Reverse *10+ Reminder; } printf("Reverse of entered number is = %d ", Reverse); if ( Number == Reverse ) printf(" %d is Palindrome Number. Object can be anything, a number, a string, phrase, etc. Palindrome number:-If the Reverse of a number is equal to the same number then the number is called a palindrome number. C Recursion : Exercise-16 with Solution. If both are the same, it's a palindrome otherwise not. I have to write a program that takes user input and determines if the input is a palindrome. Program to check if an Array is Palindrome or not. Palindrome Number in C A palindrome number is a number which is equal to its reverse. 19, Mar 19. We offer ProGrad Certification program, free interview preparation, free aptitude preparation, free programming preparation for tech job aspirants. For example 1221, 11221221 i. Program to check if an Array is Palindrome or not using STL in C++. Get Python Mobile For example, "abcc" is lexicographically smaller than "abcd" because the first position they differ is at the fourth character, and 'c' is smaller than 'd'. Here, we will develop the palindrome number program in C. If you want to find a palindrome of length 3, what you can do is to divide the input array into smaller subarrays of length 3. 5225 = 5225 So, 5225 is a palindrome number. An integer is a palindrome if the reverse of that number is equal to the original number. For example 121, 34543, 343, 131, 48984 are the palindrome numbers. So, if the input is like s = "racecar", then the output will be True. Now how can we check a string that it is a palindrome or not? We can do it by using simple character type of arrays. The easiest way to check if a number is palindrome or not is by reversing the number. For example: 121 or Oppo etc. We will write one C++ program to take one string from the user as input. palindrome Program For String using String function Palindrome number check program in C: In this article, we are going to see how to use bitwise operators to find whether a number (binary representation) is palindrome or not? Submitted by Radib Kar, on December 26, 2018 Problem statement: Write a C program to check whether a number (binary representation) is palindrome or not using bitwise I'm fairly new to C and I'm having a little bit of a problem. Given a singly linked list, find whether it’s a palindrome are not. c++ palindrome program without arrays Excercise. Program to Check whether a String is Palindrome in C++. Use string Copy Constructor With rbegin/rend Methods to Check for String Palindrome in C++ If the characters at each of the positions of the old char array are the same as the new char array, then the string is a palindrome. h> void main() { char string[50]; int len, i, x, flag=0; cout<<"Enter a String (max 49 characters): "; cin. html_____Give a Like_____ C Program to Check whether the Given Number is a Palindromic C Program to Check whether the Given Number is a Palindromic If a number, which when read in both forward and backward way is same, then such a number is called a palindrome number. Write a C program to find next smallest palindrome of a given number. The above function is made by using C#. Online C++ strings programs and examples with solutions, explanation and output for computer science and information technology students pursuing BE, BTech, MCA, MTech, MCS, MSc, BCA, BSc. C Program – Generating palindrome numbers in a given range In C we represent boolean values with 1 or 0. A palindrome number is a number that is same after reverse. C++ if, if else and Nested if else. g. Code using while loop using C++. We are given a linked list with 1 forward direction, we can convert the list to a vector, which has O(1) random access time compare to O(n) using linked list. For example, Numbers like 0,1,2,11,44,121,222,242,345543 are called as Palindrome Numbers. Coding of Palindrome (number/string) in C++. For example, 191 is a palindrome number because this number remains the same after reversing the number. We have to solve this problem using pointers in C. For example 121, 34543, 343, 131, 48984 are the palindrome numbers. For e. To understand below example, you have must knowledge of following C++ programming topics; For Loop in C++ and Reverse Number Program in C++. For example, 141 is a palindrome number but 122 is not. they are identical then the entered string is a palindrome otherwise not. h> void main(){ int num, r, sum =0, t; printf("Input a number: "); scanf("%d",& num); for( t = num; num !=0; num = num /10){ r = num % 10; sum = sum *10+ r; } if( t == sum) printf("%d is a palindrome number. The function SequenceEqual () has been used to compare strings and function Reverse () reverses the string. Easy. The question is, write a program in C to enter any string at run-time and check whether it is palindrome or not. palindrome sample; program to check whether string is palindrome in c without using string functions; c program for palindrome string without using string functions; java program for palindrome without using string functions; palindrome in java without using string function C++ Program to Check Armstrong Number In this example, you will learn to check whether a number entered by the user is an Armstrong number or not. Logic to check palindrome number. For example 121, 34543, 343, 131, 48984 are the palindrome numbers. 2) c=0,calculate the string length n using strlen (s) library function. A palindrome number is a number that is given the same number after reverse. Loop over a string in both directions. For example, Numbers like 0,1,2,11,55,131,262,464,453354 are called as Palindrome Numbers. If the reverse of a number is equal to the number itself, it is called a palindrome number. 1842 3693 Add to List Share. The string is read from left to right and right to left and each character is matched. ", string); else printf(" [ %s ] is not a palindrome string. For example, the main is a function and every program execution starts from the main function in C programming. 10. techyrick. Some examples are 8, 121, 212, 12321, -454. Pictorial Presentation: Sample Solution: In this blog, we will learn How to write a program to check whether a String is a Palindrome or not in C#. A palindrome string is one that reads the same backward as well as forward. techyrick. For vertical strings, you need to do the same thing for the columns. In this article we have shared two C programs to check if the input number is palindrome or not. How to Check Palindrome Linked List in C/C++? A palindrome is a string/number that mirrors itself, for example, 21312 reverse is also 21312. If it is, then we change the last character to ‘b’. The following steps are the standard procedure to check for the Palindrome Number in C Programming. html_____Give a Like_____ A palindrome is a number or a string which is similar when read from the front and from the rear. Recursive Approach: The idea is to take 2 pointers pointing at the first character and the other at the end character and check if both characters are equal until we reach the middle of the string. 19, Mar 19. e it reads the same from both sides (front to end) or (back to front). Palindrome Program using While Loop. If the reversed integer is equal to the integer entered by user then, that number is a palindrome if not that number is not a palindrome. palindrome in c