[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: 808ercise: Shell Golf



> > After two more worthy attempts, I'll post my solution. 
> I give up.

Here's my attempt (111 characters):

file .??* *|(IFS=:;while read f b;do 
echo "$b"|grep script >/dev/null&&grep -i that\ pays "$f" /dev/null;done)

I miscounted earlier (I was using a shorter test phrase). My bad.
Using 'grep -q' might shorten it up, but Solaris doesn't have that option,
and that's where I was first trying to do this.

Mike808/

---------------------------------------------
http://www.valuenet.net



-
To unsubscribe, send email to majordomo@silug.org with
"unsubscribe silug-discuss" in the body.