Programmming Archive

Great little perl snippet to let you know the number of files and directories in the current directory. Run from the command line.
ls -l |perl -e ‘while(<>){$h{substr($_,0,1)}+=1;} END {foreach(keys %h){print “$_ $h{$_}\n”;}}’

You ever programming and need some reference material? I know when I do it is sometimes hard to find teh exact info you need, maybe its not in one of your cheat sheets, or its one of those obscure once a decade things you need to find. I know I run across those type of [...]