in reply to Re^5: Stuck on packages
in thread Stuck on packages
#!/usr/bin/perl package Foo; sub new { my $class = shift; return bless { engine => "engine", wheels => "wheels" }, $class; } sub get_as_array { my $self = shift; return [ $self->{engine}, $self->{wheels} ]; } 1; my $foo = Foo->new; print $foo->get_as_array;
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^7: Stuck on packages
by shigetsu (Hermit) on Jan 04, 2007 at 10:09 UTC | |
|
Re^7: Stuck on packages
by blazar (Canon) on Jan 04, 2007 at 21:07 UTC |