how to use grep command to list find the records of a file
containg 10 different strings

Answer Posted / umakanta

grep -w 'word1|word2' filename

Is This Answer Correct ?    8 Yes 14 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How would you explain a kernel to a non-technical person?

532


In unix, what is echo used for?

581


What are hidden files in unix?

517


Is unix a programming language?

494


Is unix more secure than windows?

455






What are data structures that are used for Demand Paging?

569


Why unix terminals are called dummy terminals?

536


How to get the n-th field from a Unix command output?

555


What is unix shell scripting used for?

473


How do I check disk space in unix?

486


Which mode executes the fault handler?

593


What are pipes and filters in unix?

611


Is windows built on unix?

509


How to null a file in unix?

630


You have a file called tonky in the directory honky. Later you add new material to tonky. What changes take place in the directory, inode, and file?

706