Is this shell programming right?# Unix - 噫吁兮,危乎高哉m*a2004-12-31 08:121 楼I want to display the count of different words in a text file,will this do?tr '[A-Z]' '[a-z]'|sort|uniq -c|sort -rn
c*e2004-12-31 08:122 楼No, sort and uniq is operating by lines not words【在 m****a 的大作中提到】: I want to display the count of different words in a text file,will this do?: tr '[A-Z]' '[a-z]'|sort|uniq -c|sort -rn
p*f2004-12-31 08:123 楼What is the problem with ``wc -w''?【在 m****a 的大作中提到】: I want to display the count of different words in a text file,will this do?: tr '[A-Z]' '[a-z]'|sort|uniq -c|sort -rn
a*n2004-12-31 08:124 楼Give you a hint, you can use associate array to do it.【在 m****a 的大作中提到】: I want to display the count of different words in a text file,will this do?: tr '[A-Z]' '[a-z]'|sort|uniq -c|sort -rn