- or download this
package Organism;
...
}
1;
- or download this
for my $c (keys %{ $cells }) {
- or download this
while ( my ($c) = each %{ $cells } ) {
- or download this
sub tick {
my $self = shift;
...
+ exists($cells->{pack 'i2', $x2, $y2}) == 3 ) } @zcells
} keys %{$cells};
}
- or download this
sub tick {
my $self = shift;
...
} keys %{$cells} } = undef;
$self->{Cells} = \%newcells;
}
- or download this
my @zcells = (
($k1 = pack 'i2', $x1, $y1) x !exists($cells->{$k1}),
...
($k6 = pack 'i2', $x2, $y1) x !exists($cells->{$k6}),
($k7 = pack 'i2', $x2, $y0) x !exists($cells->{$k7}),
($k8 = pack 'i2', $x2, $y2) x !exists($cells->{$k8}) );
- or download this
my @zcells = grep( !exists($cells->{$_}),
pack('i2', $x1, $y1),
...
pack('i2', $x2, $y1),
pack('i2', $x2, $y0),
pack('i2', $x2, $y2) );
- or download this
sub tick {
my $self = shift;
...
}
$self->{Cells} = \%newcells;
}