Vidyalelo
Computer Science · Q102

UNIX

Engineering and GATE · Computer Science · question 102

Q102

Which command is used to move all files to the bin sub-directory of the parent directory?

A.
mv *.* /bin/
B.
mv * /bin/*
C.
mv * ../bin
Answer
D.
mv * ../bin *.*
E.
None of the above

Answer: Option C

Solution

Answer: Option C
Solution:
The mv command is used to move files or directories. In this case, the wildcard * is used to select all files in the current directory, and ../bin specifies the bin sub-directory of the parent directory as the destination.
Options A, B, and D are incorrect as they either specify incorrect destination directories or use incorrect wildcard patterns.