Mastering Unix Commands
18 Questions
0 Views

Choose a study mode

Play Quiz
Study Flashcards
Spaced Repetition
Chat to lesson

Podcast

Play an AI-generated podcast conversation about this lesson

Questions and Answers

Which command is used to compress a file?

  • gzip (correct)
  • wc
  • grep
  • gunzip
  • Which parameter is used with the 'grep' command to perform a case insensitive search?

  • -l
  • -r
  • -n
  • -i (correct)
  • Which command is used to count lines, words, and bytes of a file?

  • gunzip
  • gzip
  • wc (correct)
  • grep
  • Which command is used to sort the contents of a file in reverse order?

    <p>sort -r</p> Signup and view all the answers

    Which command is used to remove consecutive duplicate lines from a file?

    <p>uniq</p> Signup and view all the answers

    Which command is used to extract specific fields from each line of a file using a delimiter?

    <p>cut</p> Signup and view all the answers

    The 'gzip' command is used to decompress a gzipped file.

    <p>False</p> Signup and view all the answers

    The 'grep' command can be used to search for a specific pattern in a file.

    <p>True</p> Signup and view all the answers

    The 'wc' command can only count lines in a file.

    <p>False</p> Signup and view all the answers

    The 'sort' command can only sort files based on alphanumeric values.

    <p>False</p> Signup and view all the answers

    The 'uniq' command removes all duplicate lines in a file, even if they are not consecutive.

    <p>False</p> Signup and view all the answers

    The 'cut' command can extract specific fields from each line of a file using a delimiter.

    <p>True</p> Signup and view all the answers

    Which command is used to compress a file?

    <p>gzip</p> Signup and view all the answers

    What parameter is used with the 'grep' command to perform a case insensitive search?

    <p>-i</p> Signup and view all the answers

    Which command is used to count lines, words, and bytes of a file?

    <p>wc</p> Signup and view all the answers

    Which command is used to redirect output to a file?

    <p>cat</p> Signup and view all the answers

    What does the 'uniq' command do?

    <p>Removes consecutive duplicate lines from a file</p> Signup and view all the answers

    What does the 'cut' command do?

    <p>Extracts specific fields from each line of a file</p> Signup and view all the answers

    More Like This

    Mastering UNIX Command-Line
    5 questions
    Mastering UNIX
    5 questions

    Mastering UNIX

    ExcitingRhodonite3899 avatar
    ExcitingRhodonite3899
    Mastering Small Talk Guide
    10 questions

    Mastering Small Talk Guide

    FeasibleMeadow7499 avatar
    FeasibleMeadow7499
    Use Quizgecko on...
    Browser
    Browser