Write a script to check entered string or a number is
palindrome or not
Program =
#!/bin/bash
echo "Utsav Gohel -
91900104011"
echo "Enter number"
read number
realnumber=$number
n=`expr $number % 10`
number=`expr $number / 10`
while [[ $number -ne 0 ]]
do
n=`expr $n \* 10 $number % 10`
number=`expr $number / 10 `
done
if [[ $n -eq $realnumber ]];
then
echo "Palindrome"
else
echo "Not Palindrome"
fi
Output =