/en-s5-ict-number-systems-database-sql-normalisation-file-size-cpu-programming-algorithms-networking-subnetting-compression-security-practice-paper/
/en-s5-ict-number-systems-database-sql-normalisation-file-size-cpu-programming-algorithms-networking-subnetting-compression-security-practice-paper/
General Inquiry: info@TutorZone.com.hk
Office Hours: Monday to Saturday - 9:00 AM to 6:00 PM
WhatsApp Monday to Sunday - 24 hours
Hotline: +852 6828 1809
Instant Support: +852 9061 3106

S5 Information and Communication Technology Practice Paper: Binary and Hexadecimal Conversion, Two’s Complement, SQL and Normalisation, Multimedia File Sizes, CPU Execution Time, Algorithm Tracing, Bubble Sort, Binary Search, IPv4 Subnetting, Bandwidth and Compression, Information Security (100 marks)

S5 Information and Communication Technology Practice Paper: Binary and Hexadecimal Conversion, Two’s Complement, SQL and Normalisation, Multimedia File Sizes, CPU Execution Time, Algorithm Tracing, Bubble Sort, Binary Search, IPv4 Subnetting, Bandwidth and Compression, Information Security (100 marks)

  • 2026-11-21

Information and Communication Technology · S5

S5 ICT practice paper: 24 questions, 100 marks, 75 minutes on number systems, SQL, file sizes, CPU timing, algorithms, subnetting and security, with a full answer key.

Paper details S5 ICT practice paper with a full answer key: 24 questions, 100 marks, 75 minutes covering binary and hexadecimal conversion, two’s complement, SQL, normalisation, multimedia file sizes, CPU execution time, algorithm tracing, subnetting and security.

Part 1 Number Systems and Data Representation (16 marks)

Show all conversion and calculation steps.

# Question Answer and marking notes
1 Convert 11010110 binary to denary and hexadecimal, and write out the place value expansion. Place value: 128+64+16+4+2 = 214 denary. Grouping 4 bits: 1101 = D and 0110 = 6, so hexadecimal is D6.
2 Convert 3A9F hexadecimal to denary and to 16-bit binary. 3*4096 + 10*256 + 9*16 + 15 = 15007 denary; in binary it is 0011101010011111.
3 Represent -46 in 8-bit two’s complement and explain the meaning of the most significant bit. 46 = 00101110, invert to 11010001, add 1 to get 11010010; the MSB of 1 marks a negative number with place value -128.
4 A passage has 500 Chinese characters and 300 ASCII characters stored in UTF-8. Compute the number of bytes and bits. Bytes = 500*3 + 300*1 = 1800; bits = 1800*8 = 14400 (about 1.76 KiB).

Part 2 Data Organisation, Databases and SQL (16 marks)

Write complete executable SQL statements (upper case keywords are accepted).

# Question Answer and marking notes
5 Explain the relationship between a primary key and a candidate key, with one example. A candidate key uniquely identifies each row; the primary key is the candidate key chosen for the table and the others become alternate keys. Example: student ID as primary key with HKID as another candidate key.
6 The table Student(SID, Name, Class) exists. Write an SQL statement listing the names of class 5A students in ascending name order. SELECT Name FROM Student WHERE Class = ‘5A’ ORDER BY Name ASC; (ASC is optional because ascending is the default.)
7 One column stores two phone numbers “9123 4567, 9876 5432”. State which normal form is violated and how to fix it. It violates first normal form (1NF: each cell must hold a single atomic value). Fix it by creating Phone(SID, PhoneNo) with a composite primary key and a one-to-many relationship to the original table.
8 Table Orders has 240 rows: 96 with Amount >= 500, 150 with Status = ‘PAID’ and 60 satisfying both; table Customers has 12 rows. Write the SQL counting rows with Amount >= 500 and paid, and compute the Cartesian product size. SELECT COUNT(*) FROM Orders WHERE Amount >= 500 AND Status = ‘PAID’; the result is 60 rows. Cartesian product = 12*25 = 300 rows, so an unconstrained join of the two tables returns 300 rows.

Part 3 Computer Systems and Multimedia File Sizes (17 marks)

Unless stated otherwise, 1 MiB = 1,048,576 bytes and 1 MB = 1,000,000 bytes.

# Question Answer and marking notes
9 A 4000 by 3000 pixel bitmap uses 24-bit colour and is uncompressed. Compute its size in bytes and MiB (1 MiB = 1,048,576 bytes). Pixels = 4000*3000 = 12,000,000; each pixel takes 3 bytes, so the file is 12,000,000*3 = 36,000,000 bytes = 34.3 MiB.
10 A 180-second stereo recording uses a 44,100 Hz sampling rate and 16-bit samples with no compression. Compute its size in bytes and MiB. Size = 44,100*2 bytes*2 channels*180 s = 31,752,000 bytes = 30.3 MiB.
11 A 2-minute video has a bit rate of 4 Mbps. Compute its size in MB and MiB. Bits = 4,000,000*120 = 480,000,000; divided by 8 gives 60,000,000 bytes = 60 MB = 57.2 MiB.
12 A CPU runs at 3.2 GHz with an average CPI of 2.5 and executes 8*10^9 instructions. Compute the number of clock cycles and the execution time. Cycles = 8e9*2.5 = 2e+10; time = 2e+10 / 3.2e9 = 6.25 seconds.

Part 4 Programming and Algorithms (17 marks)

Show the value of every variable in each iteration.

# Question Answer and marking notes
13 Trace the pseudocode and give the output and the value of total after each iteration.
total <- 0
FOR i <- 1 TO 5
total <- total + i*i
NEXT i
OUTPUT total
The terms are 1, 4, 9, 16 and 25, so total becomes 1, 5, 14, 30 and 55; output = 55.
14 Using binary search on 1,000 sorted records, what is the maximum number of comparisons? Show the derivation. Each comparison halves the search space; 2^9 = 512 < 1,000 <= 1,024 = 2^10, so at most 10 comparisons (O(log n)).
15 Perform the first pass of bubble sort (ascending, comparing adjacent pairs left to right) on [45, 12, 78, 33, 9]. Give the list after the first pass. Comparisons: swap 45 and 12; keep 78; swap 78 with 33; swap 78 with 9. After pass one the list is [12, 45, 33, 9, 78] and the largest value 78 has bubbled to the end.
16 One algorithm is O(n log2 n) and another is O(n^2). For n = 1,024, compute the operations of each and the ratio. O(n log n) is about 1,024*10 = 10,240 operations; O(n^2) is 1,024^2 = 1,048,576; the ratio is about 102.4 times, so O(n log n) scales far better.

Part 5 Networks, the Internet and Subnetting (17 marks)

State the formula and the unit used.

# Question Answer and marking notes
17 A network uses a /26 subnet mask. Compute the addresses per subnet, the usable hosts per subnet and the dotted decimal mask. Host bits = 32-26 = 6, so addresses = 2^6 = 64; usable hosts = 64-2 = 62 after removing the network and broadcast addresses; the mask is 255.255.255.192.
18 A 45 MiB file is sent over a 12 Mbps link. Compute the time needed in seconds. Data = 45*8 = 360 Mbit; time = 360/12 = 30 seconds.
19 A 24 MiB file compresses to 7.5 MiB. Compute the compression ratio and the percentage saved. Ratio = 24/7.5 = 3.2:1; saving = (24-7.5)/24*100% = 68.75%.
20 A web page is 1.5 MiB in total, the link runs at 20 Mbps and the round trip time is 60 ms. Compute the total download time assuming no other delay. Transfer time = 1.5*8/20 = 0.6 s; adding the RTT of 0.06 s gives 0.6599999999999999 s in total.

Part 6 Information Systems, Compression and Security (17 marks)

Answer security and literacy questions with reference to Hong Kong law.

# Question Answer and marking notes
21 A 15-minute 1080p video has a bit rate of 8 Mbps. Compute its size in MB and GiB (1 GiB = 1,024 MiB). Bits = 8*900 = 7,200 Mbit; divided by 8 gives 900 MB = 0.88 GiB.
22 Compare symmetric and asymmetric encryption and explain how a digital signature gives both authentication and integrity. Symmetric encryption uses one shared key: fast, but the key must be distributed securely. Asymmetric encryption uses a public key to encrypt and a private key to decrypt, solving distribution but slower. A digital signature encrypts the message digest with the sender private key, so the receiver verifies it with the public key and any digest mismatch shows tampering.
23 An employee uploads customer HKID numbers and medical records to an unencrypted public cloud. Name the Hong Kong ordinance likely breached and three improvements. It may breach the Personal Data (Privacy) Ordinance (Cap. 486), especially data security (DPP4) and purpose limitation (DPP3), since medical records are sensitive. Improvements: upload only the minimum de-identified data, encrypt end to end with access control, and set a cloud contract plus staff training and audit logs.
24 A 250 GiB backup set compresses to 40 per cent of its original size and is copied to a 4 TB (4,000 GB) disk. Compute the compressed size and how many full backups fit. Compressed size = 250*40% = 100 GiB; the disk holds 4,000 GiB, so 4,000/100 = 40 full backups fit.

Find a tutor — freeTutor Registration →

A TutorZone practice paper; original questions and passages, not publisher material.

Join as a tutor or coach — academic, music, sports, arts, STEM. Free to register. See how it works →