Welcome to ExamTopics
ExamTopics Logo
- Expert Verified, Online, Free.
 

CompTIA LX0-104 Exam Actual Questions

The questions for LX0-104 were last updated on Nov. 16, 2024.
  • Viewing page 1 out of 45 pages.
  • Viewing questions 1-4 out of 179 questions

Topic 1 - Shells, Scripting and Data Management

Question #1 Topic 1

What is true regarding the statement beginning with #! that is found in the first line of a script?

  • A. It prevents the script from being executed until the ! is removed.
  • B. It specifies the path and the arguments of the interpreter used to run the script.
  • C. It is a comment that is ignored by the script.
  • D. It specifies the character encoding of the script.
Reveal Solution Hide Solution   Discussion  

Correct Answer: B 🗳️

Question #2 Topic 1

Which Bash option prevents a user from accidentally overwriting a file with a ">"?

  • A. set -o safe
  • B. set -o noglob
  • C. set -o noclobber
  • D. set -o append
  • E. set -o nooverwrite
Reveal Solution Hide Solution   Discussion  

Correct Answer: C 🗳️

Question #3 Topic 1

Which of the following commands prints the exit value of the most recently executed program in Bash?

  • A. echo $?
  • B. echo $#
  • C. echo $exit
  • D. echo $status
  • E. echo $&
Reveal Solution Hide Solution   Discussion  

Correct Answer: A 🗳️

Question #4 Topic 1

SIMULATION -
What word will complete an if statement in bash such as the following: if [ -x "$file" ]; then echo $file _____
(Please provide the missing word only)

Reveal Solution Hide Solution   Discussion  

Correct Answer: fi

Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.

Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.

SaveCancel
Loading ...