Question

unix lunix question A file called dataTest has the following lines: A big cat The cat...

unix lunix question

A file called dataTest has the following lines:
A big cat
The cat
bad data
begger rat
bigger rat
boogy

Specify the lines which will be displayed as a result of the following commands:

grep -E "b.*g?" dataTest
grep -E "gg+" dataTest

0 0
Add a comment Improve this question Transcribed image text
Answer #1

command:

grep -E "b.*g?" dataTest

Output:

===========================================================

Command:

grep -E "gg+" dataTest

Output:

==========================================================

Kindly Check and Verify Thanks..!!!

Add a comment
Know the answer?
Add Answer to:
unix lunix question A file called dataTest has the following lines: A big cat The cat...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • QUESTION 1 What will be the output of following Unix command: find / -name ‘*’ A....

    QUESTION 1 What will be the output of following Unix command: find / -name ‘*’ A. List all files and directories recursively starting from / B. List a file names * in / C. List all files in / directory D. List all files and directories in / directory QUESTION 2 Which command is used to extract a column/field from a text file / input. A. paste B. get C. cut D. tar QUESTION 3 Which command creates an empty...

  • Which of the following statements is true about file names in Unix? A file name can...

    Which of the following statements is true about file names in Unix? A file name can contain hyphens and underscores. A file name can contain slashes (/). A Unix file name must end in a period () followed by a 1-3 character file extension Some files names can only be typed in commands using quoting. A file name can contain blank spaces. Moving to another question will save this response.

  • linux help Create a file called trees, containing the following individual lines: Oak tree Pine Tree...

    linux help Create a file called trees, containing the following individual lines: Oak tree Pine Tree Spruce tree Cottonwood Maple tree Pine Tree Copy in the contents of the trees to more_trees file. Next, add the following trees at the end of the list. Redwood Willow tree Use a command to compare the trees and more_trees files and show the differences in terms of individual lines that differ. Determine the number of bytes in both the trees and more trees...

  • Question 11 1 point possible (graded) The commands in the pipeline $ cat result.txt | grep...

    Question 11 1 point possible (graded) The commands in the pipeline $ cat result.txt | grep "Harvard edX" | tee file2.txt | wc -l perform which of the following actions? From result.txt, select lines containing “Harvard edX”, store them into file2.txt, and print all unique lines from result.txt. From result.txt, select lines containing “Harvard edX”, and store them into file2.txt. From result.txt, select lines containing “Harvard edX”, store them into file2.txt, and print the total number of lines which were...

  • QUESTION 1 From YOUR home directory, execute a find command string that will locate the file...

    QUESTION 1 From YOUR home directory, execute a find command string that will locate the file called resolv.conf. Include the -exec flag in the find command to cat the file to the screen. Begin your find search from the letc directory Select the correct find command string below that will accomplish this. find /etc-name 'resolv.conf -cat D find /etc-name 'resolv.conf -exec cat 0 find. -name 'resolv.conf -exec cat 0\ find /-name 'resolv.conf' -exec cat 0 QUESTION 2 What find command...

  • Unix HOMEWORK HELP!! Simple Multiple Choice.   I have answered these questions, but I want to ask...

    Unix HOMEWORK HELP!! Simple Multiple Choice.   I have answered these questions, but I want to ask online, to get second feedback and make sure I am on the right page What is the diffference bettween a willd card and a regular expression? a.) A willd carrd is the * chharacter, butt a rregular excpression caan usse morre symbols. b.) Wild cards are pattterns expandded by the shhell. A reggular expression is a pattern used by commands, internally. c.) There is...

  • Unix questions, i need help on Hint: Commands to study to answer this question: predefined shell...

    Unix questions, i need help on Hint: Commands to study to answer this question: predefined shell variables, and .profile script file, echo SHELL, HOME, PATH, MAIL and TERM are predefined shell variables. You can use the value of a shell variable in a shell command putting $ in front of it. For example, to display the value of the HOME directory of the user, specify $HOME in the echo command like echo $HOME. Do not give just the value of...

  • used Linss file systems d FAT nd NTFS NTFS and est3 h ReiserFS and ext3 15....

    used Linss file systems d FAT nd NTFS NTFS and est3 h ReiserFS and ext3 15. A fie a hem ppicaly you might possibly sreae entries for all the ie than enongheir that file sy stemtains ore than enough 16. To create a syesbolic link, use the a. In command h In command with the -s optiorn d. symlink command You can learn numerous details about any file using the 17 s brip2 and buenion etitities in Linux? d. gzip...

  • C ++ Implement cat command The purpose of this assignment is to provide practice using the...

    C ++ Implement cat command The purpose of this assignment is to provide practice using the system calls we discussed for working with files on a UNIX system. You will be writing a basic implementation of the cat command using C++. Description As you should recall, the cat command takes a list of files as command line arguments. It then opens each file in turn, writing each file’s entire contents to standard output in the order they were supplied. You...

  • A filename con comprise multiple embedded dots (e.g., a.b.c.d.e). True False A device file is not...

    A filename con comprise multiple embedded dots (e.g., a.b.c.d.e). True False A device file is not really a stream of characters and doesn't contain anything at all. True False Relative pathnames begin with the root directory. True False Running the ls -a command uniquely identifies directories and binary executables. True False What is the result of running mkdir -p share/man/cat1 from the command line? a. It creates the directory share. b. It creates the directory share/man. c. It creates the...

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
Active Questions
ADVERTISEMENT