sub write_graffiti { my $self = shift; my %params = @_; $self->{colour} = $params{colour} if defined $params{colour}; # spray paint wall with the colour, # whether new or existing } #### sub colour { my $self = shift; my $colour = shift if @_; $self->{colour} = $colour if defined $colour; return $self->{colour}; }