Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change
 
PerlMonks  

Answer: How do I insert, (not overwrite) into a string?

by turnstep (Parson)
on Aug 23, 2000 at 20:08 UTC ( #29243=categorized answer: print w/replies, xml ) Need Help??

Q&A > strings > How do I insert, (not overwrite) into a string? - Answer contributed by turnstep

Regular expressions can handle this just fine as well:
my $string = "ello"; $string =~ s/^/Henry said H/;

Log In?
Username:
Password:

What's my password?
Create A New User
Chatterbox?
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others meditating upon the Monastery: (7)
As of 2017-01-23 19:09 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Do you watch meteor showers?




    Results (194 votes). Check out past polls.