Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic
 
PerlMonks  

Re: Line break interpretation

by Molt (Chaplain)
on Oct 19, 2006 at 17:06 UTC ( #579402=note: print w/replies, xml ) Need Help??


in reply to Line break interpretation

Another approach which may be suitable if it's only line-breaks you're interested in may be to use a substitution.
#!/usr/bin/perl use strict; use warnings; my $msg = 'Hello\nWorld'; print "Msg was $msg\n"; $msg =~ s/\\n/\n/g; print "Msg is $msg\n";

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://579402]
help
Chatterbox?
[Corion]: Hmm - the longer I work, the more such sentences I collect:
[Corion]: "If I wanted to work with people, I would have become a coroner."
[Corion]: "If I wanted to work with hot air, I would have become a baloonist"
[Corion]: "If I wanted to work with flaps, I would have become a mailman"
[Corion]: (I'm not sure if the last one works in English too ;) )

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (8)
As of 2017-09-21 14:28 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    During the recent solar eclipse, I:









    Results (248 votes). Check out past polls.

    Notices?