Ask Question

Which one of the following commands will list the contents of a directory, and put those listed contents into a file called "mydir"? 1s - pla > mydir 1s - pla mydir

+5
Answers (1)
  1. 22 April, 21:09
    0
    ls - pla > mydir

    Explanation:

    ls is the command to list the contents of the directory.

    -p option indicate / as the designator for directories

    -l options enables line by line entries for files

    -a option lists all files including special files starting with.

    > is used for redirecting the output of the ls command to the specified file.

    So ls - pla > mydir will run ls command with - pla option and populate the file mydir with the contents of the result.
Know the Answer?
Not Sure About the Answer?
Find an answer to your question 👍 “Which one of the following commands will list the contents of a directory, and put those listed contents into a file called "mydir"? 1s - ...” in 📗 Computers & Technology if the answers seem to be not correct or there’s no answer. Try a smart search to find answers to similar questions.
Search for Other Answers