On Sat, 21 Apr 2001 [EMAIL PROTECTED] wrote:

> Since I'm new at Unix, I decided that I would take a Unix class. I'm at
> the end of the semester and I have my last assignment. It is writting a
> shell script, which the book nor the instructor covered well. I have to
> write a script called lookup. when run, lookup should find the matching
> entries from a file called .addr_book and display the entry.
> example   lookup john doe
> output    john doe Phone:888-8888
> how am i able to write this script with only using grep an sort. I've
> been at it for days. oh, by the way, he says that the script should only
> be three lines long. Ha!
> if you can help, please let me know ...thanx
>
>
>
Here is a big hint.  The line that does the work will be something like:

grep "$1 $2" .addr_book

This is if you call the script using something like "lookup john doe"

Mikkel
-- 

    Do not meddle in the affairs of dragons,
 for you are crunchy and taste good with ketchup.



_______________________________________________
Redhat-list mailing list
[EMAIL PROTECTED]
https://listman.redhat.com/mailman/listinfo/redhat-list

Reply via email to