■第二回、PerlOO入門 - HelloWorld -■
#OoHelloWorld.pm
package OoHelloWorld;
sub new{bless {};}
sub hello_world{'Hello,World!';}
1;
#OoHelloWorldUsing.pl
package OoHelloWorldUsing;
use OoHelloWorld;
my $oo=new OoHelloWorld;
print $oo->hello_world;