Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

write a shell program to check wheather a given string is
pallindrome or not?

Answer Posted / mahesh gupta

this script is written for bash :
echo Enter the string
read s
echo $s > temp
rvs="$(rev temp)"
if [ $s = $rvs ]
then
echo "it is palindrome"
else
echo " it is not"
fi

Is This Answer Correct ?    21 Yes 6 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How do you create a shortcut in linux?

1205


Is shell script a programming language?

1038


How to print the first array element?

1039


How to get the last line from a file using just the terminal?

1232


How do I run a .sh file on mac?

1195


What does $1 mean in bash?

1099


How to pass an argument to a script?

1211


How can I set the default rwx permission to all users on every file which is created in the current shell?

1429


What happens when you type ls?

1000


I want to connect to a remote server and execute some commands, how can I achieve this?

1025


What is console line?

966


What is bash coding?

930


How to calculate the number of passed arguments?

1105


Tell something about the super block in shell scripting?

1035


How will you pass and access arguments to a script in linux?

1158