Reverse a string : Reverse « String « Perl






Reverse a string

   

$string = "Hello!";

$reversed = reverse($string);
print "$reversed\n";

   
    
    
  








Related examples in the same category

1.Reverses the word order of the input file.