ITN 170 Module 3 (3 of 6)

Lakukan tugas rumah & ujian kamu dengan baik sekarang menggunakan Quizwiz!

In order to move from the /home/joe/test/data to the /home/joe directory, what command should be issued? - cd .. - cd ../.. - /home/joe - cd ./..

cd ../..

What command can be issued to confirm which directory you are in at a command line prompt? - dir - pwd - whereami - ld

pwd

When issuing the ls -F command, what special character indicates a linked file? - @ - * - & - =

@

Select the regular expression metacharacter that matches 0 or more occurrences of the previous character. - * - ? - + - ^

*

Chase is trying to extract records for employees 423 through 428 out of a comma separated values file and store them in another one. Which of the following commands would accomplish this? (Choose all that apply.) - cat employees.csv | grep 423,424,425,426,427,428 > employees.csv - cat employees.csv | grep "42[3-8]" > employees-newhires.csv - grep "42[3-8]" employees.csv > employees-newhires.csv - grep "42[3-8]" < employees.csv > employees-newhires.csv

- cat employees.csv | grep "42[3-8]" > employees-newhires.csv - grep "42[3-8]" employees.csv > employees-newhires.csv - grep "42[3-8]" < employees.csv > employees-newhires.csv

To display a text file in reverse order, what command should be used? cat tac tee sed

???

At the vi command mode prompt, what key combination will force a quit from the vi editor without saving changes? - :q - :q! - :exit - :!

:q!

When using the vi text editor, which of the following keys, when in command mode, will change to insert mode and place the cursor at the end of the current line? - i - a - I - A

A

Which of the following key combinations, commonly used in the vi editor command mode, displays current line statistics? - $ - x - Crl+g - P

Crl+g

When using the vi text editor, which of the following keys, when in command mode, will move to the last line in the document? - G - L - P - W

G Correct. A capital G will move the cursor to the last line in the document.

If enough unique letters of a directory name have been typed, what key can be pressed to activate the BASH shell's completion feature? - Alt - Tab - Ctrl - Esc

Tab

Kate wants to compare two text files to identify what might have been changed from one version to another. Which of the following commands can she use to do this? - match document1.txt document2.txt - version --compare document1.txt document2.txt - compare document1.txt document2.txt - diff document1.txt document2.txt

diff document1.txt document2.txt

What command is most effective at identifying different types of files? - stat - ls -l - ll - file

file

Garrett wants to search through a csv file to find all rows that have either the name John or Bob in them and display them out to the terminal. Which of the following commands could Garrett use to perform this search? - grep -E "(John|Bob)" salesemployees.cvs - grep (John|Bob) salesemployees.csv - grep -E (John|Bob) salesemployees.csv - egrep (John|Bob) salesemployees.csv

grep -E "(John|Bob)" salesemployees.cvs

Jo has received a text file which contains multiple instances of his name spelled correctly as well as multiple instances spelled as Joe. Which of the following commands would search a text file for any occurrences of either spelling and display them out to the terminal? (Choose three.) grep "Joe?" document1.txt grep -E "Joe?" document1.txt grep "Joe*" document1.txt grep -E "Joe*" document1.txt

grep -E "Joe?" document1.txt grep "Joe*" document1.txt grep -E "Joe*" document1.txt

Which of the following commands will not interpret regular expressions, which translates into faster results being returned? (Choose all that apply.) - grep - grep -F - egrep - fgrep

grep -F fgrep

Select the command that can be used to provide a long listing for each file in a directory: - ls -T - ls -L - ls -F - ls -l

ls -l

Mike has changed directory into one subdirectory after the next and has lost track of where he's at in the directory tree. Which of the following commands can he use to tell him the full path to the current subdirectory he is in? - cd - - pwd - cwd - ls -dir

pwd

What command can be used to display the last five lines of a text file? - end -5 - head -5 - stop -5 - tail -5

tail -5


Set pelajaran terkait

Allocation of Support Departments

View Set

Emt Ch 23 Gynecologic Emergencies

View Set

Chapter 1: Economics: Foundation and Models

View Set

Network+ Guide to Networks (Eighth Edition) Chapter 1 Review Questions

View Set

Euro SG Absolutism and Constitutionalism

View Set