Quiz Space

System Commands · End Term · 3 Sept 2023 · May 2023 term · Set QPD1-S1

Question 4: In a text file named "numbers.txt", multiple lines contai…

Question 4

+6 marksOne correct option

In a text file named "numbers.txt", multiple lines contain numbers. You want to delete all lines that have a number greater than 100. Which sed command would you use?
Hint: By default, SED uses the Basic Regular Expression Engine (BRE)

  1. A
  2. B
  3. C
  4. D
Show answer

Correct answer

  • A

Question 4 of 15 in the IIT Madras BS System Commands (System Commands) End Term paper sat on 3 Sept 2023, in the May 2023 term (IIT M DIPLOMA ET1 EXAM QPD1 S2 03 Sep). It carries 6 marks.

More questions from this paper

  1. Q1Select the correct statement from the options for the following command.
  2. Q2Figure question
  3. Q3Which of the option is the correct output of the following command?
  4. Q5Select the correct statement from the options for the following SED command.
  5. Q6Figure question
  6. Q7Figure question
  7. Q8Figure question
  8. Q9Figure question
  9. Q10Choose the corner case(s) from stdin that makes this SED command fail to replace all the three- character month names w…
  10. Q11Figure question
  11. Q12Figure question
  12. Q13Figure question
  13. Q14What is the output of the first loop at the end of the execution of the given script?
  14. Q15What will be the output of the second loop after the execution of the given script?