in reply to oh for y///e
What are you trying to do with the /e switch? eval 'b-zaZA-Y'? I don't see the point. And if you want to eval the result, just do eval y/a-zA-Z/b-zaZA-Y/r while <DATA>;
And if you just put the /e by mistake, just take it away and your code will work just fine.
What are you trying to do with the /e switch? eval 'b-zaZA-Y'? I don't see the point.
$cryped = substitution_cypher();
$text =~ y/a-z/$crypted/e;
eval "\$text =~ y/a-z/$crypted/";
Conway's Game of Life
Perl regular expressions
My Magic 8-Ball™
Results (191 votes). Check out past polls.