Beefy Boxes and Bandwidth Generously Provided by pair Networks
Just another Perl shrine
 
PerlMonks  

Re^2: repeat characters in text

by blazar (Canon)
on May 03, 2007 at 10:43 UTC ( #613351=note: print w/ replies, xml ) Need Help??


in reply to Re: repeat characters in text
in thread repeat characters in text

You have the right idea, you just need a different operator - print 'a', '!' x 5; will do it. Though Perl doesn't care, I prefer not to use double quotes unless I expect interpolation to be taking place.
print "a@{['!' x 5]}"; # :-)


Comment on Re^2: repeat characters in text
Select or Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others taking refuge in the Monastery: (13)
As of 2014-07-30 17:22 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My favorite superfluous repetitious redundant duplicative phrase is:









    Results (237 votes), past polls