303-300 · Question #65
Which permission bit allows a file to be executed?
The correct answer is C. Execute. Execute (C) is the permission bit that allows a file to be run as a program - without it, even a perfectly written script will be rejected by the OS when you try to launch it. Read (A) only allows viewing file contents; Write (B) only allows modifying them - neither grants the…
Question
Which permission bit allows a file to be executed?
Options
- ARead
- BWrite
- CExecute
- DSetUID
How the community answered
(18 responses)- B6% (1)
- C94% (17)
Explanation
Execute (C) is the permission bit that allows a file to be run as a program - without it, even a perfectly written script will be rejected by the OS when you try to launch it.
Read (A) only allows viewing file contents; Write (B) only allows modifying them - neither grants the ability to run a file. SetUID (D) is a special permission that runs a file as its owner's identity (e.g., root), but it only matters after execute is already set - it doesn't itself grant execution.
Memory tip: Think R-W-X in order (Read, Write, eXecute) - X is always the third bit and the one that "starts" the file.
Topics
Community Discussion
No community discussion yet for this question.