1.

Which of the following flag will be used for interactive substitution?(a) g(b) G(c) gc(d) cgThe question was asked by my school teacher while I was bunking the class.I want to ask this question from Commands for Searching, Replacing and Substituting in Vi Editor in section The Vi Editor of Unix

Answer» CORRECT option is (c) gc

The best I can explain: For selectively replacing a STRING we can use ‘gc’ flag. Here ‘c’ is used as a confirmatory parameter at the end. Each line is SELECTED in turn and then waits for our response, whether to replace the selected PATTERN or not. A ‘y’ PERFORMS the substitution and any other response doesn’t.


Discussion

No Comment Found

Related InterviewSolutions