Beefy Boxes and Bandwidth Generously Provided by pair Networks vroom
Clear questions and runnable code
get the best and fastest answer
 
PerlMonks  

Re: Scalar assignment with loop iterator considered bad?

by Adam (Vicar)
on Jul 22, 2005 at 15:30 UTC ( [id://477324]=note: print w/replies, xml ) Need Help??

This is an archived low-energy page for bots and other anonmyous visitors. Please sign up if you are a human and want to interact.


in reply to Scalar assignment with loop iterator considered bad?

In this particular scenario, I'd use join(). Why write code to do what a native perl function will do for you? From a functionality perspective, letting join() do the work is probably better than concatenating a bunch of stuff in a loop. I'm sure you could come up with some example where looping was better - if, say, you were doing other stuff at the same time.
  • Comment on Re: Scalar assignment with loop iterator considered bad?

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://477324]
help
Sections?
Information?
Find Nodes?
Leftovers?
    Notices?
    hippoepoptai's answer Re: how do I set a cookie and redirect was blessed by hippo!
    erzuuliAnonymous Monks are no longer allowed to use Super Search, due to an excessive use of this resource by robots.