1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Random Linux+ Question #48

Discussion in 'Linux+' started by tripwire45, Jul 28, 2005.

  1. tripwire45
    Honorary Member

    tripwire45 Zettabyte Poster

    13,493
    179
    287
    Sed is a stream text editor used at the command line. Sed allows you to edit text files on a line-by-line basis. The typical sed command syntax is:
    Code:
    set "editing-command" filename
    By default, when you use the sed command it will print all lines of a document after they have been processed (In this case, the term "print" refers to the standard output on the screen). This can be cumbersome if the document is long. Of the options below, which commands can you issue with sed to suppress the output of sed only prints those lines you have specified for printing? Select three answers.

    1. --suppress
    2. --silent
    3. --quiet
    4. -n
    5. -s
    6. -q

    Answer later.
     
    Certifications: A+ and Network+
  2. starfury6

    starfury6 Nibble Poster

    53
    0
    33
    I'd guess at 2, 3 and 6. No experience of sed whatsoever...
     
    Certifications: RHCT4, RHCT5
    WIP: SCSA
  3. ffreeloader

    ffreeloader Terabyte Poster

    3,661
    106
    167
    I'll guess 4 as my sed experience is pretty limited, but from my reading I seem to remember something about -n.
     
    Certifications: MCSE, MCDBA, CCNA, A+
    WIP: LPIC 1
  4. tripwire45
    Honorary Member

    tripwire45 Zettabyte Poster

    13,493
    179
    287
    Answer time. Guess I'll have to give partial credit to the both of you. The correct answers are 2, 3, and 4: --silent, --quiet, and -n.

    Also, I made a mistake when I posted the question. I typed the word "set" when describing the syntax instead of "sed". :oops:
     
    Certifications: A+ and Network+

Share This Page

Loading...