nerdexam
LPI

117-101 · Question #274

You want to save vi changes to the file myfile with :w!, but vi complains it can not write to the file. Therefore, you want to check the write permissions on the file. To do this without leaving vi…

The correct answer is A. :!ls -l myfile. See the full explanation below for the reasoning.

Question

You want to save vi changes to the file myfile with :w!, but vi complains it can not write to the file. Therefore, you want to check the write permissions on the file. To do this without leaving vi, you type:

Options

  • A:!ls -l myfile
  • B:\ls -l myfile
  • Cesc :ls -l myfile
  • D:?ls -l myfile

How the community answered

(35 responses)
  • A
    77% (27)
  • B
    14% (5)
  • C
    6% (2)
  • D
    3% (1)

Community Discussion

No community discussion yet for this question.

Full 117-101 Practice