Visit Jeremy's Blog.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 09-28-2012, 06:02 PM   #1
LQ Newbie
Registered: Sep 2012
Posts: 1

Rep: Reputation: Disabled
Help with EGREP in terminal

I'm using an open terminal, and changing directories to /usr/share/dict. There is a file called words in dict that contains every word in the english language. I also have to use the egrep command. What command would you use to:

-list all words that have the letter 'a' followed immediately by the letter z

-list all words that have the letter a followed sometime later by the letter z (there must be one letter in between)

Essentially the command line would be

egrep ...... words


Last edited by raoulduke666; 09-28-2012 at 06:27 PM.
Old 09-28-2012, 06:43 PM   #2
Senior Member
Registered: May 2006
Location: USA
Distribution: Debian
Posts: 4,824

Rep: Reputation: 615Reputation: 615Reputation: 615Reputation: 615Reputation: 615Reputation: 615
This sounds like homework, which I won't do for you.

man 7 regex
or Google.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
using grep and egrep in the terminal KumARan23 Linux - Newbie 3 11-11-2007 09:27 AM
egrep question internal_war Linux - Newbie 6 05-05-2005 06:32 PM
Help with egrep smart_sagittari Linux - Newbie 2 05-02-2005 08:18 AM
Using Grep and Egrep linux-nerd Linux - General 5 10-10-2004 11:37 AM
Using egrep Barbarian Programming 5 10-20-2002 02:54 PM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 02:26 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration