I have many words [MM] in a file.
I ran this command:
cat file.txt | tr " " "\n"| sort | uniq > uniq.out
I found that there are many chinese words and some alphanumeric and with special characters
I want to get all the words which are just english [A-Z][a-z] ONLY
grep -E "[A-Za-z]" uniq.out | grep -Ev "[0-9]" | less
The above command also matches alpha-numeric words.
Any suggestions ?
Thanks!
Use
( Your regex just said that it had to contain 1 a-z character for the line to count as a match)