nerdexam
LPI

117-101 · Question #89

While editing a file in vi, you realize that you are changing the wrong file. What vi command sequence will allow you to quit without saving your changes?

The correct answer is B. :q! See the full explanation below for the reasoning.

Question

While editing a file in vi, you realize that you are changing the wrong file. What vi command sequence will allow you to quit without saving your changes?

Options

  • A:Q!
  • B:q!
  • C:w!
  • D:wq!

How the community answered

(29 responses)
  • A
    3% (1)
  • B
    83% (24)
  • C
    3% (1)
  • D
    10% (3)

Community Discussion

No community discussion yet for this question.

Full 117-101 Practice