Question: 1. Create a new file called fruit.basket: Fred apples 20 Susy oranges 5 Mark watermellons 12 Robert pears 4 Terry oranges 9 Lisa peaches 7

1. Create a new file called fruit.basket: Fred apples 20 Susy oranges 5 Mark watermellons 12 Robert pears 4 Terry oranges 9 Lisa peaches 7 Susy oranges 12 Mark grapes 39 Anne mangoes 7 Greg pineapples 3 Oliver rockmellons 2 Betty limes 14

Use GREP to answer all of the questions below:

2. I want to identify every line which contained the string mellon

Q1: What command should I use? Enter the command in your VM - what is the output?

2. I want to also print out the line numbers associated with each match.

Q2: What option do I add? Enter the command - what is the output?

3. Now I only want to know how many matches are made.

Q3: What command option do I use? Enter the command - what is the output?

4. What if I want to identify rows that have two or more consecutive vowels in a string?

Q4: What command would you use? Enter the command - what is the output?

5. Now, I want only those rows that contain is or go or or

Q5: What command would you use? Enter the command - what is the output?

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!