sub method { my $self = shift; my $i = shift; my $old = $self->{B}[$i]; $self->{B}[$i] = shift if @_; $old; }