nerdexam
LPI

101-500 · Question #416

Which of the following command lines creates or, in case it already exists, overwrites a file called data with the output of ls?

The correct answer is C. ls > data. You've hit your Sonnet limit · resets Jun 8, 9am (UTC)

Shells and Shell Scripting

Question

Which of the following command lines creates or, in case it already exists, overwrites a file called data with the output of ls?

Options

  • Als 3> data
  • Bls >& data
  • Cls > data
  • Dls >> data

How the community answered

(28 responses)
  • B
    11% (3)
  • C
    86% (24)
  • D
    4% (1)

Explanation

You've hit your Sonnet limit · resets Jun 8, 9am (UTC)

Topics

#Output Redirection#Redirection Operators#File Overwriting#I/O Redirection

Community Discussion

No community discussion yet for this question.

Full 101-500 Practice