Unix commands using grep to specify a pattern -
i have file named lastnames.txt
lists 100 lastly names percentage of popularity 0 100. question how utilize grep
create new file contains lastly names 0.000
percent popularity only. note: utilize unix commands , code used:
grep '0.000' lastnames.tab > unpopularnames.tab
when utilize command lastly names greater percentage 0.000.
try doing :
grep '\b0\.000\b' lastnames
the dot .
mean any character in regex \.
mean literal .
\b
means word boundaries unix grep command
No comments:
Post a Comment