Computer Science - Unix

Exercise : Unix - Section 2
16.
Which of the following commands is used to absolutely assign all permissions to the owner, read and write permissions to the group and only executable permission to the others of the file note?
chmod 761 note
chmod 671 note
chmod 167 note
chmod 4=rwx, g=rw note
None of the above
Answer: Option
Explanation:
No answer description is available. Let's discuss.

17.
The chmod ugo+rw note command can be represented in octal notation as
chmod 555 note
chmod 666 note
chmod 444 note
chmod 333 note
None of the above
Answer: Option
Explanation:
No answer description is available. Let's discuss.

18.
Which of the following commands is used to display the filenames in multiple columns with indication of directories and executable file?
ls -F -x
ls -l
ls ~ x
Ip
None of the above
Answer: Option
Explanation:
No answer description is available. Let's discuss.

19.
Which command is used with vi editor to search a pattern in the forward direction?
/
?
//
??
None of the above
Answer: Option
Explanation:
No answer description is available. Let's discuss.

20.
Which of the following commands is used to assign executable permission to the owner of the file named "note"?
chmod g+x note
chmod u+w note
chmod u+x note
chmod ugo+x note
None of the above
Answer: Option
Explanation:
Users selection:

u - user: the owner of the file.
g - group: users who are members of the file's group.
o - others: users who are not the owner of the file or members of the group.
a - all: all three of the above, is the same as ugo.

Permissions:

r - read
w - write
x - execute

So, u+x => Execute (x) permission to Owner (u).