Sponsored Content
Top Forums Shell Programming and Scripting please help (closed homework thread) Post 50790 by djeung on Sunday 2nd of May 2004 07:44:01 PM
Old 05-02-2004
please help

I have these questions for my unix class that I can't figure out because I missed a couple of days. They are for a quiz we took last week so by answering the questions you are not bettering my grade or doing my homework. I just want to understand was the answers. My teacher is really bad at explaining things.


1. Matcha line containing the assignment of a value to a legal shell variable in grep.

2. Match a word containing a repeating sequence of characters, with one or more characters in between, in grep, e.g., match "abcxyabc" or "xax", but not "abcd" or "aa".

3. Exchange the second and third words on a line with at least 4 words in sed, leaving the rest unchanged, e.g., "hi there joe kool" becomes "hi joe there kool", but "hi there joe" is unchanged.

4. Match lines containing one or more letters immediately followed by one or more digits in grep, e.g., match "abc123" or "a7" but not "az-12".

5. Match lines containing a repeating sequence of letters followed at any distance by one or more digits in grep, e.g., match "axax123" or "aaxyz7" but not "az12" in grep.
 

4 More Discussions You Might Find Interesting

1. Post Here to Contact Site Administrators and Moderators

my thread got closed

I had a thread open and now it says it's closed. I had a question still on the forum and about 15mins after I posted my most recent question on it the thread said "closed". Why did this happen? I didn't violate any forum rules. Is there a limit on how many postings you can have in a single thread?... (1 Reply)
Discussion started by: hpicracing
1 Replies

2. Post Here to Contact Site Administrators and Moderators

Thread closed when learner has tried

I'm not so sure that this thread should have been closed. Though it was clearly homework the student was asking a specific question related to the assignment, but not the answer to the whole assignment. /www.unix.com/unix-dummies-questions-answers/107494-how-get-rid.html . IMHO The solution is... (1 Reply)
Discussion started by: methyl
1 Replies

3. UNIX for Dummies Questions & Answers

3 homework questions (thread closed)

1st) how can i print only directories? 2nd) how can i print files that someone used in the last X days (for example, 5). thanks very much, i need it for homework and teacher teachs us nothing:( (1 Reply)
Discussion started by: SupErioR
1 Replies

4. Solaris

Interview questions [thread closed]

Hi all, i have found a set questions from the net, i thought it will be great to ask and share with you gurus. I have the questions and some answers (correct me, if i am wrong) for these set of questions. 1. What file do you modify to change the mail aliases (Provide the full path) ? Ans:... (1 Reply)
Discussion started by: kingston
1 Replies
look(1) 							   User Commands							   look(1)

NAME
look - find words in the system dictionary or lines in a sorted list SYNOPSIS
/usr/bin/look [-d] [-f] [-tc] string [filename] DESCRIPTION
The look command consults a sorted filename and prints all lines that begin with string. If no filename is specified, look uses /usr/share/lib/dict/words with collating sequence -df. look limits the length of a word to search for to 256 characters. OPTIONS
-d Dictionary order. Only letters, digits, TAB and SPACE characters are used in comparisons. -f Fold case. Upper case letters are not distinguished from lower case in comparisons. -tc Set termination character. All characters to the right of c in string are ignored. FILES
/usr/share/lib/dict/words spelling list ATTRIBUTES
See attributes(5) for descriptions of the following attributes: +-----------------------------+-----------------------------+ | ATTRIBUTE TYPE | ATTRIBUTE VALUE | +-----------------------------+-----------------------------+ |Availability |SUNWesu | +-----------------------------+-----------------------------+ SEE ALSO
grep(1), sort(1), attributes(5) SunOS 5.11 29 Mar 1994 look(1)
All times are GMT -4. The time now is 02:25 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy