gloomy.penguin
  • Portland, OR, United States
  • Member for 6 years, 7 months
Stats
397
reputation
5k
reached
0
answers
1
questions
Loading…
About

.

#!/usr/bin/perl 

package me; 
# brave new world - huxley
# Was and will make me ill. 
# I take a gramme and only am. 

sub exist {
   my $class = shift; 
   bless {'am'=>'kim'}, $class;     
}

sub think {
   my ($self,$thought) = @_;
   $self->{'am'} = 'ill'; 
}

sub take {
   my ($self,$something) = @_;
   $self->{'am'} = undef 
      if ($something =~ /gram(me)?(s)?/i);
}

sub am {
   my $self = shift; 
   print $self->{'am'} 
         if defined $self->{'am'}; 
   print "\n";
} 

my $i = me->exist();  
   $i->think('was');  
   $i->am(); 
   $i->think('will');  
   $i->am(); 
   $i->take('gramme');
   $i->am(); # now nothing
This user doesn’t have any gold badges yet.
4
silver badges
5
bronze badges

Top tags (4)

Score 0
Posts 1
Posts % 100
Score 0
Posts 1
Score 0
Posts 1
Score 0
Posts 1

Top posts (1)