Skip to content
IGCSE·Tuition
Computer Science · Practice

Images, sound and storage: mixed practice with explanations

You can follow each worked example in the lessons, yet a mixed set is where you find out which step you really own.

This set mixes the skills from images, sound and storage: image size, audio size, compression, trade-offs and unit conversion. Questions run from easy to harder. Use the binary convention (1 KiB = 1 024 bytes, 1 MiB = 1 024 KiB) unless a question says otherwise, and state any assumption.

Attempt each question on paper and show every step before opening the answer. The pseudocode trace trainer and the Python reasoning sandbox can check your method, and the mistake log is useful for recording what went wrong.

Questions

Q1. An image uses 8 different colours. What is the smallest colour depth, in bits, that can store them?

Show answer

23 = 8, so 3 bits. (2 bits give only 4 colours, which is not enough.)

Q2. A bitmap is 32 × 32 pixels with an 8-bit colour depth. Give its size in bytes and KiB, uncompressed.

Show answer

Pixels = 32 × 32 = 1 024. Bits = 1 024 × 8 = 8 192. Bytes = 8 192 ÷ 8 = 1 024 bytes = 1 KiB. Assumes no compression and no metadata.

Q3. A screen capture is 1 280 × 720 pixels at 24-bit colour depth. Give the uncompressed size in KiB and in MiB (to 2 decimal places).

Show answer

Pixels = 1 280 × 720 = 921 600. Bits = 921 600 × 24 = 22 118 400. Bytes = 22 118 400 ÷ 8 = 2 764 800. KiB = 2 764 800 ÷ 1 024 = 2 700 KiB. MiB = 2 700 ÷ 1 024 = 2.6367… = 2.64 MiB.

Check: 24 bits = 3 bytes, and 921 600 × 3 = 2 764 800. Matches.

Q4. A mono sound clip lasts 20 seconds, with a sample rate of 16 000 Hz and a 16-bit sample resolution. Give its uncompressed size in bytes and KiB.

Show answer

Bits = 16 000 × 16 × 20 = 5 120 000. Bytes = 5 120 000 ÷ 8 = 640 000 bytes. KiB = 640 000 ÷ 1 024 = 625 KiB.

Q5. The same clip from Q4 is recorded in stereo. What is the new size in KiB, and why?

Show answer

Two channels are sampled, so the size doubles: 625 × 2 = 1 250 KiB.

Q6. Compress this row of pixels with run-length encoding: WWWBBWWWWW. Is the method lossless or lossy? Explain.

Show answer

Runs: 3 W, 2 B, 5 W. Encoded: W3 B2 W5. It is lossless because decoding rebuilds exactly WWWBBWWWWW with nothing missing.

Q7. Convert 7 680 KiB to MiB.

Show answer

7 680 ÷ 1 024 = 7.5 MiB. Check: 7.5 × 1 024 = 7 680.

Q8. A hospital stores X-ray images that doctors use to diagnose patients. Should it use lossless or lossy compression? Justify your answer.

Show answer

Lossless. Lossy compression permanently removes data, and lost detail could affect a diagnosis. Lossless allows every pixel to be rebuilt exactly, even though the files are larger.

Q9. A voice recording is made at 44 100 Hz and then re-recorded at 22 050 Hz, with the same length, bit depth and channels. Explain the effect on file size and on quality.

Show answer

The sample rate is halved, so the file size is halved. Fewer samples are taken each second, so the wave is captured less closely and the sound may be less clear. For speech this reduction may be acceptable, which is the trade-off.

Q10. An uncompressed 640 × 480 image takes 150 KiB. What colour depth does it use?

Show answer

Bytes = 150 × 1 024 = 153 600. Bits = 153 600 × 8 = 1 228 800. Pixels = 640 × 480 = 307 200. Depth = 1 228 800 ÷ 307 200 = 4 bits.

Check: 307 200 × 4 = 1 228 800 bits. Matches.

Q11. An 8 MiB file is compressed to 2 MiB. By what fraction and what percentage has it been reduced?

Show answer

Reduction = 8 − 2 = 6 MiB. Fraction = 6/8 = 3/4, which is 75%. The compressed file is one quarter of the original size.

Q12. A file has 3 000 000 bytes. Give its size in KiB using the binary convention (to 2 decimal places) and in kB using the decimal convention.

Show answer

Binary: 3 000 000 ÷ 1 024 = 2 929.6875 = 2 929.69 KiB. Decimal: 3 000 000 ÷ 1 000 = 3 000 kB. The numbers differ because the conversion factors differ, so always state the convention.

If you got these wrong

What went wrongGo back to
Used 256 as a bit depth, or forgot to divide by 8 (Q1, Q2, Q3, Q10)Calculate an uncompressed image size
Left time in minutes, or forgot the channels (Q4, Q5)Calculate a sampled audio size
Could not encode a run, or chose the wrong method (Q6, Q8, Q11)Distinguish lossless and lossy compression
Gave a one-sided answer with no size or quality link (Q9)Explain a quality-storage trade-off
Multiplied when you should divide, or mixed 1 000 and 1 024 (Q7, Q12)Convert storage units

What next?

Record any wrong question in the mistake log with the step that failed, and retry a similar question after a few days. If the same step keeps failing, a teacher can watch your working and find the habit behind it in online one-to-one Computer Science tuition.

Updated:

Your next step

If the same kind of question keeps going wrong in this set, a one-to-one teacher can sit with your working and find the habit behind the mistake rather than just the answer.

Paid one-hour trial at your assigned teacher’s confirmed rate, starting from RM80.

Tuition is arranged with a parent or guardian. Send them this page on WhatsApp and they can enquire for you.

Parents: enquire here

  • 9,000+ students helped through our service
  • 9+ years helping IGCSE students