MCQ IN COMPUTER SCIENCE & ENGINEERING

COMPUTER SCIENCE AND ENGINEERING

UNIX

Question [CLICK ON ANY CHOICE TO KNOW THE RIGHT ANSWER]
Command used to list all hidden files is
A
Multiple Choice
B
ls-l
C
ls-d
D
ls-a
Explanation: 

Detailed explanation-1: -ls-a will list all files including hidden files (files with names beginning with a dot).

Detailed explanation-2: -To show hidden files you must use the-a option, which commands ls to list “all” files and folders (including hidden ones). Navigate to your home directory with the cd command and do a listing of all files using ls. As you can see, there are several files that start with a dot (.).

Detailed explanation-3: -in Linux and Unix systems, the files starting with . (a dot) are hidden files. To see them with the ls command, add-a or-A at your ls.

Detailed explanation-4: -To display hidden files or directories, we include the a flag in our ls command. The a flag instructs the ls command to include all files-and not ignore files starting with a dot. Using this command, we can now see both the hidden and visible files in the current directory.

There is 1 question to complete.