in reply to count of a word occurrence


1) read the file in a while loop,split and use a hash ($hash{$_}++ ).
2) use someting like the below for all unique entries in the first column.
grep 817 filename | wc -l
hth
chimni

Replies are listed 'Best First'.
Re: Re: count of a word occurrence
by jdporter (Paladin) on Mar 23, 2004 at 04:59 UTC
    That won't quite get it. Do
    cut -f1 filename | sort | uniq -c

    jdporter
    The 6th Rule of Perl Club is -- There is no Rule #6.