Beefy Boxes and Bandwidth Generously Provided by pair Networks
more useful options
 
PerlMonks  

Re^2: Control characters

by AnomalousMonk (Archbishop)
on Jun 05, 2009 at 16:55 UTC ( #768843=note: print w/replies, xml ) Need Help??


in reply to Re: Control characters
in thread Control characters

s/(.)?^O/\1/g; s/(.)?^N/\1/g;
But what do these statements really do?
>perl -wMstrict -le "for my $str (@ARGV) { printf q{%s -> }, $str; $str =~ s/(.)?^O/\1/g; $str =~ s/(.)?^N/\1/g; print $str; } " OhNoOhNo NotOnNotOn \1 better written as $1 at -e line 1. \1 better written as $1 at -e line 1. Use of uninitialized value $1 in substitution iterator at -e line 1. OhNoOhNo -> hNoOhNo Use of uninitialized value $1 in substitution iterator at -e line 1. NotOnNotOn -> otOnNotOn

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://768843]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others taking refuge in the Monastery: (4)
As of 2023-12-02 01:39 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    What's your preferred 'use VERSION' for new CPAN modules in 2023?











    Results (13 votes). Check out past polls.

    Notices?