Tartaglia Pascal and Erathostenes
Perl is dead..
game
oneliners
perl idioms
- stolen from busunsl's homenode
- slurp a file: my $contents = do { local (@ARGV, $/) = $filename; <> };
- set even elements of @list to 'bla': $_ % 2 or $list[$_] = 'bla' for 0..$#list;
- getting indices sorted by value: my @indices = sort { $a[$a] <=> $a[$b] } 0..$#a;
- initialize hash elements: @hash{@array} = (1) x @array
- assign empty string defaults: $_ = '' for grep ! defined ( $foo, $bar, $baz );
- blank padding: $str = pack('A40',$str);
some cool use of Perl
music and sounds
other useful homenodes
THIS IS THE LAST LINE
L*
There are no rules, there are no thumbs..
Reinvent the wheel, then learn The Wheel; may be one day you reinvent one of THE WHEELS.