[geeks] text file processing
Scotty Logan
swl at catbert.net
Tue Jan 6 12:50:57 CST 2004
On Jan 6, 2004, at 10:27 AM, Bill Bradford wrote:
> Anybody know how to run a text file through some sort of processor and
> find
> the most-used strings or words?
Something like this?
% tr -Cs '[:alnum:]' '\012' < textfile | tr '[:upper:]' '[:lower:]' |
sort | uniq -c | sort -nr | head -20
Scotty
--
Scotty Logan <scotty at catbert.net>
Never take life seriously - Nobody gets out alive anyway
More information about the geeks
mailing list