Give a regular expression that finds two things, try to
come up with regular expressions that find each
individually using "egrep" command?

Answer Posted / linuxdemon(vjsujay@gmail.com)

vjsujay@vjsujay-desktop:~/test$ cat jsk
cake
coke

vjsujay@vjsujay-desktop:~/test$ egrep 'c(a|o)ke' jsk
cake
coke

Is This Answer Correct ?    1 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is .sh file?

628


Explain the steps that a shell follows while processing a command.

693


What is the function of grep command in unix?

607


Why is it called grep?

573


What are the commands in UNIX to list the files in a Directory?

630






What does 'mkdir' command do in UNIX?

671


What are the differences among a system call, a library function, and a unix command?

578


What is the search command in unix?

614


Why is awk called awk?

583


What is the difference between cat command and more command?

607


How do I open a port?

600


What is the pipe command?

592


how to sort the content of the file based on numeric values

1266


What is difference between grep and find command in unix?

592


Which command is used to kill the last background job?

791