CompTIA LX0-104 - CompTIA Linux+ Powered by LPI 2 Exam
Page: 2 / 36
Total 178 questions
Question #6 (Topic: Shells, Scripting and Data Management)
FILL BLANK
By default, the contents of which directory will be copied to a new user's home directory when the account is created by passing the -m option to the useradd
command? (Specify the full path to the directory.)
By default, the contents of which directory will be copied to a new user's home directory when the account is created by passing the -m option to the useradd
command? (Specify the full path to the directory.)
Answer: /etc/skel
Question #7 (Topic: Shells, Scripting and Data Management)
FILL BLANK
What word is missing from the following SQL statement?
__________ count(*) from tablename;
(Please specify the missing word using lower-case letters only.)
What word is missing from the following SQL statement?
__________ count(*) from tablename;
(Please specify the missing word using lower-case letters only.)
Answer: select
Question #8 (Topic: Shells, Scripting and Data Management)
After issuing:
function myfunction { echo $1 $2 ; }
in Bash, which output does:
myfunction A B C
Produce?
function myfunction { echo $1 $2 ; }
in Bash, which output does:
myfunction A B C
Produce?
A. A B
B. A B C
C. A C
D. B C
E. C B A
Answer: A
Question #9 (Topic: Shells, Scripting and Data Management)
Which of the following commands puts the output of the command date into the shell variable mydate?
A. mydate="$(date)"
B. mydate="exec date"
C. mydate="$((date))"
D. mydate="date"
E. mydate="${date}"
Answer: A
Question #10 (Topic: Shells, Scripting and Data Management)
Which of the following files, when existing, affect the behavior of the Bash shell? (Choose TWO correct answers.)
A. ~/.bashconf
B. ~/.bashrc
C. ~/.bashdefaults
D. ~/.bash_etc
E. ~/.bash_profile
Answer: BE