- or download this
package Foo;
# some code here
...
return 1 if caller();
print "as a program\n";
- or download this
$ perl Foo.pm
Called as a program!
- or download this
$ perl -MFoo -e 1
$
- or download this
$ perl Bar.pm
Can't open perl script "Bar.pm": No such file or directory