📚 A-Level OCR Computer Science: Final Revision Guide | A-Level OCR 计算机:期末复习提纲
Preparing for the OCR A-Level Computer Science exams means bringing together knowledge from across the specification: from the fetch-decode-execute cycle and assembly language, through networks and databases, to computational thinking and ethical issues. This revision guide organises core topics into ten focused sections, with paired English–Chinese explanations, summary tables, and key equations. Use it as a checklist to identify weak areas and consolidate understanding before the final paper.
备战 OCR A-Level 计算机科学考试需要将整份考纲的知识融会贯通:从取指-译码-执行周期和汇编语言,到网络和数据库,再到计算思维与伦理议题。本复习指南将核心主题归纳为十个重点模块,提供中英对照讲解、汇总表格和关键公式。请将其用作自查清单,在终考前发现薄弱环节、巩固理解。
1. Computer Architecture & Assembly Language | 计算机体系结构与汇编语言
The CPU is built around the fetch-decode-execute cycle. The Program Counter (PC) holds the address of the next instruction; the Memory Address Register (MAR) and Memory Data Register (MDR) interface with RAM; the Current Instruction Register (CIR) stores the instruction being decoded; and the Accumulator (ACC) holds intermediate results. Assembly language uses mnemonics like LDA, STA, ADD, SUB, BRA, BNE that map directly to opcodes and operands. For OCR, you must trace simple programs that use immediate, direct, and indexed addressing modes.
CPU 围绕取指-译码-执行周期工作。程序计数器 (PC) 存放下一条指令的地址;内存地址寄存器 (MAR) 和内存数据寄存器 (MDR) 与 RAM 交互;当前指令寄存器 (CIR) 存放正在译码的指令;累加器 (ACC) 保存中间结果。汇编语言使用助记符如 LDA、STA、ADD、SUB、BRA、BNE,它们直接映射为操作码和操作数。OCR 要求能追踪使用立即寻址、直接寻址和变址寻址模式的简单程序。
- PC increments automatically; jump instructions overwrite it.
- PC 自动递增;跳转指令会覆盖它。
- Immediate addressing uses the operand itself as data (e.g., LDA #5).
- 立即寻址 直接使用操作数作为数据 (例如 LDA #5)。
- Direct addressing interprets the operand as a memory address.
- 直接寻址 将操作数解释为内存地址。
- Indexed addressing adds the index register (IX) to the operand to form the effective address.
- 变址寻址 将变址寄存器 (IX) 与操作数相加形成有效地址。
2. Systems Software: Operating Systems & Utilities | 系统软件:操作系统与实用工具
An operating system manages hardware resources, provides a user interface, handles interrupts, and enforces memory protection and scheduling. Key scheduling algorithms include round robin, first-come first-served, shortest job first, and multi-level feedback queues. Virtual memory uses secondary storage to simulate extra RAM, swapping pages in and out. Interrupts are handled by the Interrupt Service Routine (ISR), with priorities checked against the interrupt register.
操作系统管理硬件资源、提供用户界面、处理中断并执行内存保护与调度。主要的调度算法包括轮转法、先来先服务、最短作业优先以及多级反馈队列。虚拟内存利用二级存储器模拟额外的 RAM,进行页面的换入换出。中断由中断服务例程 (ISR) 处理,会根据中断寄存器检查优先级。
| Scheduling Algorithm | Mechanism | 调度算法 | 机制 |
|---|---|---|---|
| Round Robin | Fixed time slice, preemptive | 轮转法 | 固定时间片,抢占式 |
| FCFS | Non-preemptive, queue order | 先来先服务 | 非抢占,按队列顺序 |
| SJF | Shortest burst next, may be preemptive | 最短作业优先 | 最短执行时间者优先,可能抢占 |
Utility software performs maintenance tasks: disk defragmentation, file compression, backup, antivirus scanning, and file management. These sit on top of the OS but are not part of the kernel.
实用工具软件执行维护任务:磁盘碎片整理、文件压缩、备份、反病毒扫描和文件管理。它们运行在操作系统之上,但不属于内核。
3. Networking Fundamentals | 网络基础
The TCP/IP stack has four layers: Application (HTTP, FTP, SMTP), Transport (TCP/UDP), Internet (IP), and Link (Ethernet/Wi-Fi). Data is encapsulated with headers at each layer. Routers work at the Internet layer, forwarding packets based on IP addresses; switches work at the Link layer, using MAC addresses. DNS resolves domain names to IP addresses through a hierarchical system of root, TLD, and authoritative servers.
TCP/IP 协议栈有四层:应用层 (HTTP、FTP、SMTP)、传输层 (TCP/UDP)、互联网层 (IP) 和链路层 (以太网/Wi-Fi)。数据在每一层被加上头部进行封装。路由器在互联网层工作,根据 IP 地址转发数据包;交换机在链路层工作,使用 MAC 地址。DNS 通过根服务器、顶级域服务器和权威服务器的分层系统将域名解析为 IP 地址。
The client–server model contrasts with peer-to-peer. In P2P, every node both requests and provides services. For a LAN, star topology remains dominant; a mesh topology offers high resilience but costly wiring. Firewalls filter traffic using packet inspection or stateful inspection. Symmetric and asymmetric encryption protect data in transit; public key infrastructure uses a public/private key pair to enable secure key exchange.
客户-服务器模型与对等网络形成对比。在 P2P 中,每个节点既请求也提供服务。就局域网而言,星形拓扑仍占主导地位;网状拓扑提供高容错性但布线成本高。防火墙通过数据包检查或状态检查来过滤流量。对称和不对称加密保护传输中的数据;公钥基础设施使用公钥/私钥对来实现安全密钥交换。
4. Data Representation | 数据表示
Integers are stored in sign-and-magnitude or two’s complement. Two’s complement avoids duplicate zero and simplifies subtraction: to negate, flip bits and add 1. Floating-point notation follows ±M × RE, where M is the mantissa, R is the radix (normally 2), and E is the exponent, stored in a fixed total bit width with a bias. Normalisation maximises precision by ensuring the mantissa begins with 01 (for positive numbers) or 10 (for negatives) in binary.
整数以原码或二进制补码形式存储。二进制补码避免了负零并简化了减法:取负时按位取反再加 1。浮点表示法遵循 ±M × RE,其中 M 为尾数,R 为基数 (通常为 2),E 为阶码,以特定总位宽和偏移量存储。规范化通过确保二进制尾数以 01 (正数) 或 10 (负数) 开头来最大化精度。
负数的二进制补码:−X = (Flip bits of X) + 1
Characters are encoded with ASCII (7/8-bit) or Unicode (variable length, e.g., UTF-8). Sound is sampled at regular intervals (sample rate) and each sample quantised to a bit depth; Nyquist theorem states that the sample rate must be at least twice the highest frequency. Images are represented as pixel grids with colour depth; vector graphics describe shapes with primitives. Lossy compression (JPEG, MP3) discards less perceptible detail; lossless (PNG, FLAC) reconstructs the original exactly.
字符用 ASCII (7/8 位) 或 Unicode (变长,如 UTF-8) 编码。声音按固定间隔采样 (采样率),每个样本量化为一定的位深度;奈奎斯特定理指出采样率必须至少为最高频率的两倍。图像以像素网格表示,配有颜色深度;矢量图用图元描述形状。有损压缩 (JPEG、MP3) 丢弃不太明显的细节;无损压缩 (PNG、FLAC) 可精确重建原始数据。
5. Algorithms and Complexity | 算法与复杂度
Search and sort algorithms underpin many exam questions. Linear search is O(n); binary search is O(log n) but requires a sorted array. Bubble sort is O(n²), insertion sort is O(n²) but efficient for nearly sorted data, and merge sort is O(n log n) with O(n) space. Be able to trace each with a small dataset and explain why merge sort’s divide-and-conquer approach reduces comparisons.
搜索与排序算法是许多考题的基础。线性搜索的时间复杂度为 O(n);二分搜索为 O(log n) 但要求数组已排序。冒泡排序为 O(n²),插入排序为 O(n²) 但对接近排序的数据效率高,归并排序为 O(n log n),空间复杂度为 O(n)。要能根据小数据集追踪每一种算法,并解释归并排序的分治策略为何能减少比较次数。
Dijkstra’s algorithm finds the shortest path in a weighted graph; A* extends it with a heuristic to guide search. Understand the role of a priority queue in Dijkstra. Tree traversal (pre-order, in-order, post-order) is used for expression trees and syntax analysis. For OCR, you must be able to dry-run algorithms and comment on their efficiency using Big O notation.
Dijkstra 算法可找出加权图中的最短路径;A* 算法通过增加启发式函数来引导搜索。理解优先队列在 Dijkstra 中的角色。树的遍历 (前序、中序、后序) 用于表达式树和语法分析。OCR 要求能手工运行算法,并用大 O 表示法评论其效率。
6. Programming Techniques | 编程技巧
The OCR exam expects familiarity with Python, Java, or C#. You must handle variables, selection (if-elif-else), iteration (for, while, do-while), arrays/lists, string manipulation, and file I/O. Subroutines (procedures and functions) decompose a problem; parameter passing can be by value or by reference. Recursion must be written with a base case and a recursive step that reduces the problem size.
OCR 考试要求熟悉 Python、Java 或 C#。必须掌握变量、选择 (if-elif-else)、迭代 (for、while、do-while)、数组/列表、字符串处理和文件 I/O。子程序 (过程和函数) 用于分解问题;参数传递方式可以是传值或传引用。递归必须写出基准情形和能减小问题规模的递归步骤。
- Local vs global variables: local scope hides globals; side-effects from globals must be justified.
- 局部变量与全局变量:局部作用域会隐藏全局变量;使用全局变量带来的副作用必须有合理理由。
- Exception handling uses try-except-finally to manage runtime errors gracefully.
- 异常处理 使用 try-except-finally 来优雅地管理运行时错误。
- Object-oriented concepts: classes, objects, inheritance, encapsulation, polymorphism.
- 面向对象概念:类、对象、继承、封装和多态。
7. Databases and SQL | 数据库与结构化查询语言
Relational databases store data in tables linked by primary and foreign keys. Entity-Relationship diagrams capture entities and cardinality (1:1, 1:M, M:N). Normalisation to Third Normal Form (3NF) removes partial-key and non-key dependencies: 1NF – no repeating groups; 2NF – no partial dependencies on a composite key; 3NF – no transitive dependencies. SQL commands: SELECT, FROM, WHERE, JOIN (INNER, LEFT, RIGHT), GROUP BY, HAVING, ORDER BY, INSERT, UPDATE, DELETE.
关系型数据库将数据存储在通过主键和外键关联的表中。实体-关系图描述实体和基数 (1:1、1:M、M:N)。规范化到第三范式 (3NF) 可消除部分键依赖和非键依赖:1NF – 无重复组;2NF – 无对复合键的部分依赖;3NF – 无传递依赖。SQL 命令:SELECT、FROM、WHERE、JOIN (INNER、LEFT、RIGHT)、GROUP BY、HAVING、ORDER BY、INSERT、UPDATE、DELETE。
典型查询:SELECT name, SUM(price) FROM Orders JOIN Customers ON Orders.cust_id = Customers.id WHERE date > ‘2025-01-01’ GROUP BY name HAVING SUM(price) > 100;
ACID properties (Atomicity, Consistency, Isolation, Durability) guarantee reliable transactions. Record locking prevents lost updates in concurrent access; deadlock occurs when two transactions wait indefinitely for each other’s locks.
ACID 特性 (原子性、一致性、隔离性、持久性) 保证事务可靠性。记录锁定防止并发访问中的更新丢失;当两个事务无限期地等待对方持有的锁时会发生死锁。
8. Computational Thinking and Problem Solving | 计算思维与问题解决
Computational thinking involves decomposition, pattern recognition, abstraction, and algorithm design. In exams, you may see problems requiring identification of inputs, processes, and outputs, or tracing a flowchart or pseudocode. Abstraction hides unnecessary detail; for example, a map in a navigation app abstracts road networks to nodes and edges. Be comfortable writing pseudocode that mirrors the structure of exam-specified reference language.
计算思维包括分解、模式识别、抽象和算法设计。考试中可能会遇到要求识别输入、处理过程和输出的问题,或者追踪流程图或伪代码。抽象会隐藏不必要的细节;例如,导航应用中的地图将道路网络抽象为节点和边。要能熟练编写伪代码,其结构应贴近考试指定的参考语言。
State-transition diagrams and truth tables are tools for modelling finite-state machines. Backtracking (e.g., in maze solving) systematically explores possibilities and retreats when a dead end is reached. Careful stepwise refinement turns a rough outline into a detailed algorithm, documenting decisions along the way.
状态转换图和真值表是建立有限状态机模型的工具。回溯法 (例如在迷宫求解中) 会系统性地探索各种可能性,并在走入死胡同时回退。谨慎的逐步求精可将粗略的纲要转变为详细的算法,并在此过程中记录各项决策。
9. Ethical, Legal, and Environmental Issues | 伦理、法律与环境议题
OCR places strong emphasis on the wider impact of computing. The Data Protection Act (DPA 2018 / GDPR) governs personal data processing and upholds principles of lawfulness, fairness, transparency, purpose limitation, and data minimisation. The Computer Misuse Act criminalises unauthorised access and modification. The Copyright, Designs and Patents Act protects software and digital content. The Regulation of Investigatory Powers Act (RIPA) covers surveillance and interception.
OCR 高度重视计算技术的广泛影响。《数据保护法》(DPA 2018 / GDPR) 规范个人数据处理,并坚守合法、公平、透明、目的限制和数据最小化等原则。《计算机滥用法》将未经授权的访问和修改定为刑事犯罪。《版权、设计和专利法》保护软件和数字内容。《调查权力规制法》(RIPA) 涉及监视和监听。
- Artificial Intelligence ethics: bias in training data, accountability, transparency, job displacement.
- 人工智能伦理:训练数据的偏见、问责制、透明度、就业替代。
- Environmental impact: e-waste, data centre energy use, sustainable design, WEEE directive.
- 环境影响:电子废弃物、数据中心能耗、可持续设计、WEEE 指令。
- Moral dilemmas: whistleblowing, censorship, digital divide, software liability.
- 道德困境:检举爆料、内容审查、数字鸿沟、软件产品责任。
Always apply an ethical framework: weigh the rights of stakeholders, consider professional codes of conduct (e.g., BCS Code of Conduct), and reference relevant legislation in extended response questions.
始终运用伦理框架:权衡利益相关者的权利,考虑职业行为守则 (如 BCS 行为守则),并在拓展论述题中引用相关法律。
10. Boolean Algebra and Logic Gates | 布尔代数与逻辑门
Logic gates (AND, OR, NOT, NAND, NOR, XOR) are building blocks of digital circuits. Boolean algebra allows expression simplification using identities: De Morgan’s laws, distribution, absorption, and idempotence. A truth table exhaustively lists input combinations and corresponding outputs. Sum-of-Products (SoP) form directly implements AND-OR logic; Karnaugh maps (up to 4 variables) simplify expressions without algebraic manipulation.
逻辑门 (与、或、非、与非、或非、异或) 是数字电路的基本构件。布尔代数使用恒等式进行表达式化简:德摩根定律、分配律、吸收律和幂等律。真值表穷举列出所有输入组合及其对应输出。积之和 (SoP) 形式直接实现与-或逻辑;卡诺图 (最多 4 个变量) 无需代数操作即可化简表达式。
德摩根定律:¬(A ∧ B) = ¬A ∨ ¬B | ¬(A ∨ B) = ¬A ∧ ¬B
Flip-flops (SR, JK, D-type) are sequential circuits forming the basis of registers and memory. A D-type flip-flop captures input D on a clock edge. Half adders and full adders combine gates to perform binary addition; a full adder has inputs A, B, Cin and outputs Sum = A XOR B XOR Cin, Cout = (A ∧ B) ∨ (Cin ∧ (A XOR B)).
触发器 (SR、JK、D 型) 是时序电路,构成寄存器和存储器的基础。D 型触发器在时钟边沿采集输入 D。半加器和全加器组合门电路执行二进制加法;全加器有输入 A、B、Cin,输出 Sum = A XOR B XOR Cin,Cout = (A ∧ B) ∨ (Cin ∧ (A XOR B))。
11. Exam Technique and Common Pitfalls | 考试技巧与常见误区
Many marks are lost by misreading the command words. ‘State’ requires a short fact; ‘Describe’ needs a step-by-step account; ‘Explain’ adds reasons or justifications; ‘Compare’ demands similarities and differences. In pseudocode questions, ensure consistent indentation, proper explicit declaration, and meaningful identifiers. When tracing algorithms, update variables line by line – do not skip steps.
很多分数因误读指令词而丢失。“指出” 要求给出简短事实;“描述” 需要逐步说明;“解释” 要加上原因或理由;“比较” 则需列出异同。在伪代码题中,确保缩进一致、明确声明变量并使用有意义的标识符。追踪算法时,要逐行更新变量——不要跳步。
- Always show working in floating-point, normalisation, and binary arithmetic.
- 始终展示计算过程:浮点数、规范化及二进制算术题中要写出演算。
- Double-check units in data transfer and storage questions (bit vs byte, KB vs KiB).
- 仔细检查单位:数据传输和存储题中注意 bit 与 byte,KB 与 KiB。
- Connect legal issues to specific provisions in legislation, not generic statements.
- 法律问题要具体引用法条,不要泛泛而谈。
- Practice with past papers under timed conditions; the OCR mark scheme reveals what earns credit.
- 用历年真题计时训练;OCR 评分方案会揭示得分点。
12. Final Review Checklist | 最终复习清单
Use the following checklist to verify your readiness for the exam. Tick off each item after a self-test or practice question. If an area feels uncertain, return to your notes or seek a targeted exercise.
使用以下清单核查自己的备考程度。每完成一次自测或练习后勾选一项。若某方面仍不清晰,可回看笔记或寻找针对性的练习。
| Topic | Self-Check | 主题 | 自检 |
|---|---|---|---|
| Fetch-decode-execute & registers | □ | 取指-译码-执行与寄存器 | □ |
| Assembly language & addressing modes | □ | 汇编语言与寻址模式 | □ |
| OS, scheduling, interrupts, virtual memory | □ | OS、调度、中断、虚拟内存 | □ |
| TCP/IP stack, DNS, client-server vs P2P | □ | TCP/IP 协议栈、DNS、客户端-服务器与 P2P | □ |
| Two’s complement, floating point, normalisation | □ | 补码、浮点数、规范化 | □ |
| Search/sort algorithms & Big O | □ | 搜索/排序算法与大 O 表示法 | □ |
| Pseudocode, subroutines, recursion, OOP | □ | 伪代码、子程序、递归、面向对象 | □ |
| Normalisation to 3NF, SQL queries | □ | 规范化至 3NF、SQL 查询 | □ |
| Boolean algebra, logic gates, Karnaugh maps | □ | 布尔代数、逻辑门、卡诺图 | □ |
| Legislation (DPA, CMA, CDPA, RIPA) & ethics | □ | 法规 (DPA、CMA、CDPA、RIPA) 与伦理 | □ |
| Exam technique, command words, timing | □ | 考试技巧、指令词、时间管理 | □ |
The night before the exam, review only concise summaries and tricky topics. Get enough sleep, and bring a clear head — you have prepared thoroughly. Good luck!
考试前一晚,只复习最简洁的总结和容易出错的专题。保证充足睡眠,带着清醒的头脑走进考场——你已经准备充分。祝好运!
Published by TutorHao | Computer Science Revision Series | aleveler.com
更多咨询请联系16621398022(同微信)
屏轩国际教育cambridge primary/secondary checkpoint, cat4, ukiset,ukcat,igcse,alevel,PAT,STEP,MAT, ibdp,ap,ssat,sat,sat2课程辅导,国外大学本科硕士研究生博士课程论文辅导