nerdexam
LPI

101-500 · Question #158

In order to use the output of ls to overwrite a file called bazz, which of the following command lines would you use?

The correct answer is D. ls >> bazz. The correct answer is ‘ls >> bazz’ because it is appended.

Understand SteelHead Deployment and Initial Configuration

Question

In order to use the output of ls to overwrite a file called bazz, which of the following command lines would you use?

Options

  • Als > bazz
  • Bls >& bazz
  • Cls &> bazz
  • Dls >> bazz

How the community answered

(30 responses)
  • A
    7% (2)
  • B
    3% (1)
  • C
    13% (4)
  • D
    77% (23)

Explanation

The correct answer is ‘ls >> bazz’ because it is appended.

Topics

#bash redirection#output redirection#file append#shell I/O

Community Discussion

No community discussion yet for this question.

Full 101-500 Practice