Consider a system where each file is associated with a 16-bit number. For each…

2014

Consider a system where each file is associated with a 16-bit number. For each file, each user should have the read and write capability. How much memory is needed to store each user's access data?

Answer: A. 16 KBConcept. A permission is a yes/no flag, so a single right costs exactly one bit of storage. An identifier of n bits can name 2n distinct objects. Therefore…

  1. A.

    16 KB

  2. B.

    32 KB

  3. C.

    64 KB

  4. D.

    128 KB

Attempted by 383 students.

Show answer & explanation

Correct answer: A

Concept. A permission is a yes/no flag, so a single right costs exactly one bit of storage. An identifier of n bits can name 2n distinct objects. Therefore one user’s complete access record occupies (number of objects) × (bits of rights kept per object) bits; divide by 8 for bytes and by 1024 for kilobytes.

Application.

  1. The identifier is a 16-bit number, so the system can name 216 = 65,536 files.

  2. Each user needs one read flag and one write flag for every file: 2 rights × 1 bit = 2 bits per file.

  3. Bits per user = 65,536 files × 2 bits = 131,072 bits.

  4. Bytes per user = 131,072 ÷ 8 = 16,384 bytes.

  5. Kilobytes per user = 16,384 ÷ 1024 = 16 KB.

Cross-check. Two bits are one quarter of a byte, so the record is 65,536 ÷ 4 = 16,384 bytes — the same 16 KB reached without ever converting to bits.

Contrast. The size depends entirely on how tightly the two rights are packed:

Bits kept per file

Memory per user

2 bits (read + write, bit-packed)

16 KB

4 bits

32 KB

8 bits (one whole byte per file)

64 KB

16 bits (two bytes per file)

128 KB

Bit-level packing of the two rights is what keeps the per-user record at 16 KB; padding each file’s rights out to a whole byte or more inflates it.

Explore the full course: Niacl Ao It Specialist

Loading lesson…