What command would you use to create an alias named "list" to execute ls -ail?
Linux Midterm 01 Prep - Quiz 03 (Recovery)

Quiz
•
Information Technology (IT)
•
Professional Development
•
Easy
DK Nitro5
Used 1+ times
FREE Resource
72 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
alias list='ls -ail'
alias list="ls -ail"
alias list="ls -la"
alias list='ls -l'
Answer explanation
Option B (alias list="ls -ail") is technically correct and works the same as Option A (alias list='ls -ail'). Both single quotes (') and double quotes (") can be used to create an alias in most shells, like Bash.
Here's the difference:
Single quotes (') keep everything inside them exactly as it is, without changing anything.
Double quotes (") allow things like variables or special characters to change if needed.
In this case, since no variables or special characters are involved, both A and B will work just fine.
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which command would append the contents of the /etc directory to an existing file dump.txt?
ls /etc > ~/Assignment5/dump.txt
ls /etc >> ~/Assignment5/dump.txt
cat /etc > ~/Assignment5/dump.txt
find /etc >> ~/Assignment5/dump.txt
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which command would display the first 5 pathnames from the /etc directory?
find /etc | tail -5
find /etc | wc -l
find /etc | head -5
find /etc | sort | head -5
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
To count the number of files in a directory matching the pattern Week??, which command would you use?
find . -type d -name "Week*"
find . -type f -name "Week??" | wc -l
find . -type f -name "Week?"
ls Week?? | wc -l
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
How can you redirect both standard output and error output to the same file?
command > file.txt
command 2> file.txt
command > file.txt 2>&1
command 2>1 > file.txt
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
if my current working directory is /home, and my HOME directory is /home/foo, which command copies file /bin/ls into my HOME directory under the name xx?
cp ../../bin/./ls /foo/xx
cp ./../bin/ls ../foo/xx
cp ./foo/../../bin/ls ./foo/./xx
cp ././foo/../bin/ls ../home/foo/xx
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
If I am in directory /home/user and tim is an empty sub-directory, what is true after this command line:
touch tim/./user user ; rm ./tim/user ../user/user
the command fails because the path ./tim/user does not exist
the directory user now contains a file named user
the directory tim is still empty
the command fails because the path ../user/user does not exist
the directory tim now contains a file named user
Create a free account and access millions of resources
Similar Resources on Quizizz
68 questions
Module 10 CSEC

Quiz
•
12th Grade
75 questions
LO6 PT3 COHS-280

Quiz
•
12th Grade
72 questions
Operating Systems Quiz

Quiz
•
12th Grade
67 questions
WD1 Exercise 1

Quiz
•
University
71 questions
Вопросы по сортировке

Quiz
•
11th Grade - University
73 questions
Kiểm tra kiến thức Tin học

Quiz
•
12th Grade
71 questions
Pengaruh Informatika dalam Pendidikan

Quiz
•
7th Grade
71 questions
Google Workspace ( Docs, Sheets, Slides, Meet, Sheet Advanced )

Quiz
•
Professional Development
Popular Resources on Quizizz
15 questions
Multiplication Facts

Quiz
•
4th Grade
25 questions
SS Combined Advisory Quiz

Quiz
•
6th - 8th Grade
40 questions
Week 4 Student In Class Practice Set

Quiz
•
9th - 12th Grade
40 questions
SOL: ILE DNA Tech, Gen, Evol 2025

Quiz
•
9th - 12th Grade
20 questions
NC Universities (R2H)

Quiz
•
9th - 12th Grade
15 questions
June Review Quiz

Quiz
•
Professional Development
20 questions
Congruent and Similar Triangles

Quiz
•
8th Grade
25 questions
Triangle Inequalities

Quiz
•
10th - 12th Grade