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 script to display mirror image of a entered value
and also check whether Palindrome

Answer Posted / dheeraj

print("Enter the no. to check for Palindrome : ");
my $no = <STDIN>;
chop($no);
my $rev =reverse($no);

print "Palindrom \n" if ($rev eq $no);

#Perl cannot identify the datatype until we force operation
on it;

Is This Answer Correct ?    7 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are the advantages of programming in perl?

966


What is “grep” function in perl?

953


What are the reasons that cookie server can’t handle multiple connections?

909


Explain the difference between "my" and "local" variable scope declarations. ?

997


How to sort arrays in perl?

972


What is chomp() operator/function?

998


How can you call a subroutine and identify a subroutine?

952


how to connect cisco switch uisng perl script

3794


How to convert strings into an array in perl?

905


Distinguish my and local?

927


How can you use Perl warnings and what is the importance to use them?

915


What is boolean context?

936


Explain chop?

871


List the operator used in Perl?

930


How to change a directory in perl?

893