> Hi Chas, > > Can you give me an example when one would be used over the other? So, > is > require used more for efficiency, so we load the module only if we > need it? > Thanks, > -Ben
Bit of a conundrum there, if you don't need a module, why include it in your program. Anyway you might have your own local subroutines to suit your environment and procedures and may or may not be used by your main programs . Place them in a perl program and register the program with a 'require' statement. If you get real keen, you can make a private module out of your local subroutines. I have a general purpose perl program where I lump all my odd requirements, the main one being 'trim' (a la php) for stripping leading and trailing spaces and some odd date formatting for my own use. Owen -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/