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

Re: print_notice or print $notice or print notice?

by greywolf (Priest)
on Oct 14, 2001 at 21:33 UTC ( [id://118763]=note: print w/replies, xml ) Need Help??


in reply to print_notice or print $notice or print notice?

I prefer approach 1 for the following reasons.
a) It's easy to read.
b) It allows you to change the value $notice on a whim.

I've never really thought of using approach 2 or 3 before. It would seem that they are not re-usable. I suppose approach 2 could print a variable passed in as a parameter rather than a string. That would make it re-usable but it would be very cumbersome to call it.

mr greywolf
  • Comment on Re: print_notice or print $notice or print notice?

Replies are listed 'Best First'.

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others scrutinizing the Monastery: (5)
As of 2024-04-23 16:18 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found