Year 12 Cambridge Computer Science Unit Test Mock Paper Walkthrough | 单元测试模拟卷解析

📚 Year 12 Cambridge Computer Science Unit Test Mock Paper Walkthrough | 单元测试模拟卷解析

This article walks you through a typical Year 12 Cambridge AS Computer Science unit test mock paper, covering essential concepts from data representation to recursion. Each section dissects a sample question, highlights common mistakes, and reinforces exam technique so you can approach your real test with confidence.

本文带你逐题解析一套典型的 Year 12 剑桥 AS 计算机科学单元测试模拟卷,全面覆盖从数据表示到递归等核心知识点。每一部分都会剖析一道样题、指出常见错误并强化应试技巧,帮助你自信应对真实考试。


1. Mock Paper Overview | 试卷结构概览

The mock paper is designed to mirror the Cambridge 9618 AS Paper 1 theory exam, lasting 1 hour and carrying 50 marks. It includes a mix of multiple-choice questions, short-answer items, and structured problems that test your ability to apply concepts rather than just recall facts.

本套模拟卷参照剑桥 9618 AS 理论卷设计,时长 1 小时,总分 50 分。试题涵盖选择题、简答题和结构化问题,重在考查概念应用而非简单记忆。

Candidates should expect questions on binary arithmetic, processor architecture, assembly language, interrupts, networking, databases, algorithms, and recursion. Careful reading of command words like “state”, “explain”, “describe”, and “trace” is crucial to scoring full marks.

考生需要应对二进制运算、处理器架构、汇编语言、中断、网络、数据库、算法以及递归等方面的题目。仔细区分 “state”、”explain”、”describe” 和 “trace” 等指令词是获得满分的必要条件。


2. Data Representation: Binary Addition and Overflow | 数据表示:二进制加法与溢出

One typical question asks you to add two 8-bit numbers in two’s complement, for example 01011101₂ + 00110011₂, and determine whether overflow occurs. Many students confuse overflow with a simple carry into the ninth bit, but in two’s complement overflow is detected by comparing the carry into and out of the sign bit.

一道典型题目要求将两个 8 位补码数相加,比如 01011101₂ + 00110011₂,并判断是否溢出。许多学生把溢出与简单进位混淆,但在补码系统中溢出是通过比较符号位的进位输入和进位输出来检测的。

Perform the addition column by column: the bitwise sum gives 10010000₂. The carry into the sign bit (bit 7) is 1, and the carry out of the sign bit is also 1. Because they are equal, no overflow has occurred; the result is a valid negative number, specifically -112 in decimal.

逐列相加:按位求和得到 10010000₂。符号位(第 7 位)的进位输入为 1,进位输出也为 1。二者相等,因此未发生溢出;结果是合法的负数,十进制表示为 -112。


3. Processor Fundamentals: Von Neumann Architecture | 处理器基础:冯·诺依曼架构

Questions on the Von Neumann model often ask you to explain the purpose of the Control Unit (CU) and the Arithmetic Logic Unit (ALU). The CU directs the flow of data and instructions by generating control signals, while the ALU performs arithmetic and logical operations.

关于冯·诺依曼模型的题目常要求说明控制单元(CU)和算术逻辑单元(ALU)的作用。CU 通过产生控制信号来指挥数据和指令的流动,而 ALU 则执行算术与逻辑运算。

A strong answer will also mention that both instructions and data share the same memory in Von Neumann machines, which can lead to the “Von Neumann bottleneck”. The CU fetches instructions, decodes them, and coordinates the execution cycle.

一份优秀答案还会提到在冯·诺依曼架构中指令与数据共享同一内存,这可能导致“冯·诺依曼瓶颈”。CU 负责取指令、译码并协调执行周期。


4. Registers and the FDE Cycle | 寄存器与 FDE 周期

The fetch-decode-execute cycle relies on a set of dedicated registers. The Program Counter (PC) holds the address of the next instruction to be fetched. The Memory Address Register (MAR) receives that address, and the Memory Data Register (MDR) buffers the data read from or written to memory.

取指-译码-执行周期依赖一组专用寄存器。程序计数器(PC)存放下一条待取指令的地址。存储器地址寄存器(MAR)接收该地址,而存储器数据寄存器(MDR)则缓冲从内存读取或写入的数据。

During the fetch stage, the address in PC is copied to MAR, the instruction is fetched into MDR, and then moved to the Current Instruction Register (CIR). Simultaneously, the PC is incremented. The decode stage interprets the instruction, and the execute stage carries it out, often involving the Accumulator (ACC).

在取指阶段,PC 中的地址被复制到 MAR,指令被取入 MDR 后移入当前指令寄存器(CIR),同时 PC 自增。译码阶段解读指令,执行阶段则完成操作,通常会涉及累加器(ACC)。


5. Assembly Language and Bit Masking | 汇编语言与位掩码

In our mock paper, you are given an accumulator holding 10110100₂ and the instruction AND #0x0F. The hexadecimal mask 0x0F represents the binary pattern 00001111₂. A bitwise AND operation keeps only the bits where both operands have a 1.

模拟卷中有一题:累加器当前值为 10110100₂,执行指令 AND #0x0F。十六进制掩码 0x0F 对应二进制 00001111₂。按位与运算仅保留两个操作数均为 1 的位。

The result is 00000100₂ because the high nibble is cleared and only bit 2 survives from the low nibble. When asked to state the purpose, you should explain that the mask isolates the lower four bits, effectively clearing the upper bits. Use LDA #mask / AND to set a flag based on specific bits.

所得结果为 00000100₂,因为高四位被清零,低四位中仅第 2 位保留。题目若问意图,你应解释该掩码用于分离低四位,同时清除高位。可利用 LDA #mask / AND 依据特定位设置标志。


6. Interrupts and Their Handling | 中断及其处理

When an interrupt occurs, the current instruction finishes, and the processor suspends the current program. It saves the contents of the PC and other registers (the context) before loading the address of the Interrupt Service Routine (ISR) from the interrupt vector table.

发生中断时,当前指令执行完毕,处理器挂起当前程序。它将 PC 及其他寄存器的内容(上下文)保存起来,然后从中断向量表加载对应中断服务程序(ISR)的地址。

After the ISR executes, the saved context is restored, and the original program resumes. Exam questions often require you to describe the sequence and name the registers involved. Avoid missing the step of reserving the return address: the PC value is often pushed onto the stack before jumping to the ISR.

ISR 执行完毕后,恢复所保存的上下文,原程序继续运行。考试题常要求描述这一过程并写出所涉及的寄存器。切勿遗漏保存返回地址的步骤:PC 值通常会在跳转到 ISR 之前压入堆栈。


7. Network Protocols and the TCP/IP Stack | 网络协议与 TCP/IP 栈

You might be asked to match protocols to layers: HTTP, FTP, and SMTP belong to the Application layer; TCP and UDP belong to the Transport layer; IP operates at the Internet layer; Ethernet and Wi-Fi are Link layer technologies.

你可能会遇到将协议与层次配对的题目:HTTP、FTP、SMTP 属于应用层;TCP 和 UDP 属于传输层;IP 工作在网络层;以太网和 Wi-Fi 属于链路层技术。

Be prepared to explain why TCP is used for reliable transmission (acknowledgements, sequencing, flow control) while UDP is preferred for real-time applications like VoIP due to lower overhead. Also, clarify the role of port numbers in differentiating services on the same host.

需要准备好解释为何 TCP 用于可靠传输(确认、序号、流量控制),而 UDP 因开销低更适合 VoIP 等实时应用。此外,还须阐明端口号如何在同一主机上区分不同服务。


8. SQL Queries and Database Normalisation | SQL 查询与数据库范式

A typical database question provides two tables, Customer and Order, and asks for an SQL statement to list customers who placed orders after a certain date. A correct solution uses SELECT … FROM Customer INNER JOIN Order ON … WHERE OrderDate > ‘2024-01-01’.

典型的数据库题会给出 Customer 和 Order 两张表,要求用 SQL 列出在某日期之后下过订单的客户。正确答案要用 SELECT … FROM Customer INNER JOIN Order ON … WHERE OrderDate ‘2024-01-01’。

When justifying normalisation, you need to explain that 1NF eliminates repeating groups, 2NF removes partial dependencies on the primary key, and 3NF removes transitive dependencies. Use the concrete tables to show how anomalies are prevented.

在论证范式时,需说明 1NF 消除重复组,2NF 去除部分主键依赖,3NF 消除传递依赖。要结合具体表格展示如何避免插入、删除和修改异常。


9. Sorting Algorithms: Tracing Bubble Sort | 排序算法:冒泡排序追踪

You may be given an array [5, 1, 4, 2, 8] and asked to show the state after each pass of the bubble sort. In the first pass, adjacent elements are swapped from left to right: after the first pass the array becomes [1, 4, 2, 5, 8].

题目可能给出数组 [5, 1, 4, 2, 8],要求展示冒泡排序每一趟后的状态。第一趟从左到右比较相邻元素并交换:第一趟后数组变为 [1, 4, 2, 5, 8]。

The second pass produces [1, 2, 4, 5, 8], and a final pass confirms that no more swaps occur. Some candidates miss that the largest element “bubbles” to the end each pass, so the number of comparisons can be reduced. Remember that bubble sort has O(n²) worst-case time complexity.

第二趟得到 [1, 2, 4, 5, 8],再经过一趟确认没有交换发生。一些考生忽略了每趟结束后最大元素会“冒泡”到末端,因此可以减少比较次数。牢记冒泡排序的最坏情况时间复杂度为 O(n²)。


10. Recursion and Stack Frames | 递归与栈帧

A recursion trace question might ask you to diagram the stack frames when a function factorial(4) is called. Each call creates a new frame containing the parameter n and the return address. The frames are pushed onto the call stack until the base case n=1 is reached.

递归追踪题可能要求画出调用 factorial(4) 时的栈帧。每次调用都会创建一个新帧,包含参数 n 和返回地址。帧被依次压入调用栈,直至到达基本情况 n=1。

During the unwinding phase, frames are popped and the return values are multiplied: 1×2=2, 2×3=6, 6×4=24. Highlight the danger of a missing base case, which leads to infinite recursion and a stack overflow error. Also explain how recursion uses more memory than iteration.

在回溯阶段,帧被弹出并乘法运算:1×2=2,2×3=6,6×4=24。要强调缺少基本情况将导致无限递归和栈溢出错误。同时解释递归比迭代占用更多内存的原理。


11. Common Pitfalls and Exam Tips | 常见错误与应试技巧

One frequent mistake is treating binary addition as unsigned when the question specifies two’s complement. Always confirm whether overflow should be analysed using the sign-bit carry rule. Another pitfall is confusing the MDR with the CIR—remember the MDR holds data just read from memory, while the CIR holds the instruction currently being decoded.

常见错误之一是在题目明确要求补码时仍按无符号方式处理二进制加法。务必确认是否应使用符号位进位规则分析溢出。另一个常见问题是混淆 MDR 与 CIR——记住 MDR 存放刚从内存读取的数据,而 CIR 存放当前正在译码的指令。

For SQL queries, missing a JOIN condition or forgetting to quote date literals can cost marks. In algorithm traces, ensure you follow the exact pseudocode given; do not apply optimisations like “short bubble” unless instructed. Finally, always use the correct terminology: “interrupt vector table” rather than “interrupt list”.

SQL 查询中遗漏 JOIN 条件或忘记给日期字面量加引号都会失分。算法追踪务必严格遵循所给的伪代码,除非有明确要求,否则不要擅自应用“短冒泡”等优化。最后,务必使用正确术语:如用 “interrupt vector table” 而非 “interrupt list”。


12. Summary and Key Takeaways | 总结与复习重点

This walkthrough has covered the core question types from a Year 12 Cambridge mock paper. Focus your revision on two’s complement overflow detection, the FDE cycle with all registers, bitwise masking, the interrupt handling sequence, TCP/IP layer mapping, SQL normalisation justifications, and tracing sorting and recursive algorithms.

本文的解析涵盖了 Year 12 剑桥模拟卷的核心题型。复习时要重点关注补码溢出检测、FDE 周期及各寄存器、位掩码、中断处理流程、TCP/IP 层次对应、SQL 范式论证以及排序与递归算法的追踪。

Practicing under timed conditions and reviewing official Cambridge mark schemes will help you internalise the expected answer style. Return to this walkthrough to test yourself on each section, and you will be well prepared for your unit test.

在计时条件下练习并回顾剑桥官方评分方案,有助于你内化期望的答题风格。重新回顾本文,逐节自测,你将为单元测试做好充分准备。

Published by TutorHao | Computer Science Revision Series | aleveler.com

更多咨询请联系16621398022(同微信)

Comments

屏轩国际教育cambridge primary/secondary checkpoint, cat4, ukiset,ukcat,igcse,alevel,PAT,STEP,MAT, ibdp,ap,ssat,sat,sat2课程辅导,国外大学本科硕士研究生博士课程论文辅导

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Discover more from aleveler.com

Subscribe now to keep reading and get access to the full archive.

Continue reading