Linux MCQs with answers Page - 76

Here, you will find a collection of MCQ questions on Linux. Go through these questions to enhance your preparation for upcoming examinations and interviews.

To check the correct answer, simply click the View Answer button provided for each question.

Have your own questions to contribute? Click the button below to share your MCQs with others!

+ Add Question

A

Admin • 833.24K Points
Coach

Q. Which variable tells you the history number of the current command?

  • (A) HISTCTRL
  • (B) HISTNUM
  • (C) HISTCMD
  • (D) HISTORY

A

Admin • 833.24K Points
Coach

Q. To put the date in the prompt, which string would you add?

  • (A) d
  • (B) /D
  • (C) /d
  • (D) D

A

Admin • 833.24K Points
Coach

Q. Given the following commands, which directory will the user be taken to, assuming that there is a Jason directory off each one?
debian:~# CDPATH=/documents:/shared:/music
debian:~# cd Jason

  • (A) ~/Jason
  • (B) /music/Jason
  • (C) /shared/Jason
  • (D) /documents/Jason

A

Admin • 833.24K Points
Coach

Q. Which set option will keep you from accidentally overwriting an existing file with file redirection?

  • (A) nonuke
  • (B) noklobber
  • (C) noclobber
  • (D) nowrite

A

Admin • 833.24K Points
Coach

Q. Which parameter is used to enable an option with set?

  • (A) -o
  • (B) +o
  • (C) -s
  • (D) +s

A

Admin • 833.24K Points
Coach

Q. Which test parameter returns true if a string is 0 bytes long?

  • (A) -0
  • (B) -s
  • (C) -n
  • (D) -z

A

Admin • 833.24K Points
Coach

Q. Which scripting clause matches a string to a pattern?

  • (A) while loop
  • (B) for loop
  • (C) if/else
  • (D) case

A

Admin • 833.24K Points
Coach

Q. Which command moves five lines of text into a vi buffer named a?

  • (A) “add5
  • (B) “a5dd
  • (C) A5dd
  • (D) a5dd

A

Admin • 833.24K Points
Coach

Q. Which metacharacter matches any single character?

  • (A) ,
  • (B) *
  • (C) ?
  • (D) .

A

Admin • 833.24K Points
Coach

Q. Which variable sets the mail check time to be every 10 minutes?

  • (A) MAILCHECK=600
  • (B) MAILCHECK=10
  • (C) MAIL=600
  • (D) MAIL=10

Add MCQ in this Category

If you want to share an MCQ question in this category, it's a great idea! It will be helpful for many other students using this website.

Share Your MCQ