1.

Which of the following command is used with sed for outputting as well as printing the selected lines?(a) q(b) n(c) p(d) iI have been asked this question in quiz.My query is from sed command topic in chapter Filters using Regular Expressions of Unix

Answer»

The CORRECT choice is (c) p

Explanation: GENERALLY, ‘p’ is used for PRINTING LINES. However, this command behaves in a strange manner i.e. it both displays and prints the SELECTED lines.So the selected lines will appear twice.



Discussion

No Comment Found

Related InterviewSolutions