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

Re^3: Inserting a file inside of another

by ramlight (Friar)
on Feb 20, 2010 at 13:54 UTC ( #824377=note: print w/replies, xml ) Need Help??


in reply to Re^2: Inserting a file inside of another
in thread Inserting a file inside of another

If this is just a short throw-away script, there really is no problem with your file handles. However, I do not use them even on small scripts for several reasons.

First, it is good to get in the habit of using variables for file handles; they will stand you in good stead when you start writing larger and more complex programs.

Over time a small script may not stay small. The script may just need a slight modification to do something more, and then just another tiny improvement ...

Finally, I like to reuse code I've already written wherever I can. So small snippets of code tend to get plugged into larger scripts (where it makes sends to do so.)

  • Comment on Re^3: Inserting a file inside of another

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others studying the Monastery: (4)
As of 2022-08-15 07:27 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?