QuiztudyPREMIUM
Google IT Support Professional Certificate • STUDY MODE
BASIC COMMANDS
QUESTION 1 OF 5
Using a Linux machine, you have the following directory tree: ( Image S1Q1 ) / |-- home | |-- cindy | |-- Pictures | |--Alaska | |--Canada | |-- Movies |-- var If your current path is /home/cindy/Pictures/Canada, and you want to change to the Alaska directory, which of the following commands can you use? Check all that apply. Nice work! You can use the ~ to get to the user)s home directory, and you can use the cd .. to get to the parent directory you)re currently in.
A
cd ~/Pictures/AlaskaCorrect AnswerB
cd ../AlaskaCorrect AnswerC
cd /Pictures/AlaskaD
cd /home/cindy/Pictures/AlaskaCorrect AnswerQUESTION 2 OF 5
In Bash, which of the following commands can you use to view a long list of all files in the /home directory? Check all that apply. Awesome! You can use the ls command with the -la flags to show a long list of all files in a directory.
A
list -a /homeB
ls -la /homeCorrect AnswerC
ls -l -a /homeCorrect AnswerD
ls -la ~QUESTION 3 OF 5
In Bash, which of the following commands can you use to remove a directory named: "Miscellaneous Directory?" Nice job! To remove a directory you have recursively remove the files with -r. Don)t forget that folders with spaces in the name have to be escaped with an \.
A
rm Miscellaneous DirectoryB
rm -r Miscellaneous DirectoryC
rm Miscellaneous\ DirectoryD
rm -r Miscellaneous\ DirectoryCorrect AnswerQUESTION 4 OF 5
What's the main directory in a Linux filesystem called? Great job! The root directory is the main directory in Linux. We denote it with a /.
A
Home directoryB
Root directoryCorrect AnswerC
Master directoryD
C DriveQUESTION 5 OF 5
In Bash, if you need a little help with how a command like ls works, which of the commands can you use to get more information? Check all that apply. Wohoo! The --help flag shows useful information on how to use a command, and the man command shows the manual pages of a command.
A
ls --helpCorrect AnswerB
man lsCorrect AnswerC
manual lsD
help lsReady to test your recall?
Using a Linux machine, you have the following directory tree: ( Image S1Q1 ) / |-- home | |-- cindy | |-- Pictures | |--Alaska | |--Canada | |-- Movies |-- var If your current path is /home/cindy/Pictures/Canada, and you want to change to the Alaska directory, which of the following commands can you use? Check all that apply. Nice work! You can use the ~ to get to the user)s home directory, and you can use the cd .. to get to the parent directory you)re currently in.
💡Select all 3 correct answers before submitting (0 of 3 selected).
A
cd ~/Pictures/Alaska
B
cd ../Alaska
C
cd /Pictures/Alaska
D
cd /home/cindy/Pictures/Alaska
How confident are you in this answer?