Answer
Free flashcards · International Baccalaureate IB Diploma Programme
Computer Science flashcards
50 cards covering every topic of the syllabus (First assessment 2027). Study one topic or mix them all, turn each card, and mark yourself honestly.
Study mode needs JavaScript. Every card is listed below, so you can still cover the answers and test yourself.
Choose your cards
Session complete
Worth another look:
All 50 cards
For a quick read-through or printing. Cover the right-hand side to test yourself.
Topic 1: Theme A – Concepts of computer science
- What do the control unit, ALU and registers do in a CPU?
- The control unit directs the fetch-execute cycle and the flow of data. The ALU carries out arithmetic and logic operations. Registers are very fast, small stores inside the CPU holding the data and instructions in use.
- Describe the fetch-execute cycle
- The CPU fetches the next instruction from memory, decodes what operation it specifies, then executes it (which may read or write data via the registers), and repeats for the next instruction.
- Primary vs secondary storage
- Primary storage (e.g. RAM) is directly accessible to the CPU, fast and usually volatile, but limited in capacity. Secondary storage (e.g. an SSD) is non-volatile and larger but slower, holding data and programs not in active use.
- Why is all data in a computer ultimately binary?
- The hardware stores and processes only two states. Numbers, text, images and sound are all encoded as patterns of bits; a byte is 8 bits.
- What is the role of the operating system?
- It manages the hardware resources (processor, memory, storage, devices) and mediates between applications and the machine, so programs do not need to control the hardware directly.
- How many values can n bits represent?
- 2ⁿ different values. For example, 8 bits (one byte) give 2⁸ = 256 values.
- LAN vs WAN
- A LAN (local area network) covers a small area such as one building. A WAN (wide area network) connects networks over a large geographical area; the internet is the largest WAN.
- Client vs server
- A server provides a service or resource, such as files, web pages or email, over a network. A client is a device or program that requests and uses that service.
- What do a router, a switch and a wireless access point do?
- A router forwards packets between networks using IP addresses. A switch forwards data within a LAN only to the intended device. A wireless access point lets wireless devices join a wired network.
- TCP vs UDP
- TCP is connection-based and reliable: it numbers, acknowledges and resends packets so data arrives complete and in order. UDP sends packets with no checks, so it is faster but unreliable; it suits live streaming and gaming.
- What do DHCP and HTTPS do?
- DHCP automatically assigns IP addresses and network settings to devices joining a network. HTTPS transfers web pages like HTTP but encrypts the data between browser and server.
- What is packet switching?
- Data is split into packets, each with addressing and sequence information, which travel independently across the network, possibly by different routes, and are reassembled in order at the destination.
- Why is the internet described as decentralised?
- No single computer or organisation controls it. Many independent networks are linked by routers, and data can be re-routed around a failed link or node.
- Name the four layers of the TCP/IP model (HL)
- Application, transport, internet and network interface (link). Each layer provides services to the one above, so data can be sent reliably across networks.
- Why store data in a relational database rather than a flat file?
- Data is stored once and referenced by keys, which reduces redundancy, preserves integrity when records change, and allows controlled access. A flat file duplicates related data with no way to keep copies consistent.
- Primary key vs foreign key
- A primary key uniquely identifies each record within its own table. A foreign key is a field in one table that references the primary key of a different table, linking the two.
- SQL data definition language vs data manipulation language
- DDL defines the structure of the database, e.g. creating tables. DML works with the data the database holds, e.g. SELECT, INSERT, UPDATE and DELETE.
- What do JOIN and LIKE with % do in SQL?
- JOIN combines rows from two tables where a key matches, e.g. ON Borrowers.BorrowerID = Loans.BorrowerID. LIKE with the % wildcard matches a pattern, e.g. LIKE 'Mc%' finds values starting with Mc.
- WHERE vs HAVING in SQL
- WHERE filters individual rows before grouping. HAVING filters groups after GROUP BY, usually on an aggregate such as COUNT.
- What does ACID stand for in database transactions (HL)?
- Atomicity (all of a transaction happens or none), consistency (the database stays valid), isolation (concurrent transactions do not interfere) and durability (committed changes survive failures).
- What do BEGIN TRANSACTION, COMMIT and ROLLBACK do (HL)?
- BEGIN TRANSACTION starts a group of changes. COMMIT makes them permanent. ROLLBACK undoes them, returning the database to its state before the transaction.
- Rule-based programming vs machine learning
- In rule-based programming a programmer writes the rules. In machine learning the system derives its own rules, or model, from data.
- What are training data and features?
- Training data is the set of examples a model learns from. Features are the measurable input properties of each example that the model uses to make its prediction.
- Supervised vs unsupervised learning
- Supervised learning trains on labelled data, where the correct output is known, e.g. emails marked spam or not. Unsupervised learning finds patterns or groups in unlabelled data, e.g. clustering customers.
- Name three ethical issues raised by machine learning
- Bias in training data leading to unfair or discriminatory outputs; lack of transparency in how automated decisions are reached; the environmental and energy cost of training large models.
- Give three real-world applications of machine learning
- Any three of: spam filtering, recommendation systems, image and speech recognition, medical image analysis, fraud detection, language translation.
Topic 2: Theme B – Computational thinking and problem-solving
- What is decomposition?
- Breaking a complex problem into smaller sub-problems that are easier to understand, solve and test separately.
- What is abstraction?
- Removing unnecessary detail and keeping only what matters for solving the problem, e.g. a map that shows routes but not every building.
- What is pattern recognition in computational thinking?
- Spotting similarities within or between problems, so an existing solution can be reused or a repeated task can be generalised.
- What is an algorithm?
- A finite, ordered sequence of unambiguous steps that solves a problem or completes a task.
- Why design a solution in pseudocode or a flowchart before coding?
- Designing the logic separately from syntax reduces logic errors and follows the specify, decompose, abstract and test process of computational thinking.
- Linear search vs binary search
- Linear search checks each item in turn and works on unsorted data. Binary search repeatedly halves a sorted list by checking the middle item, so it needs far fewer comparisons on large lists.
- Name the three basic control structures
- Sequence (instructions in order), selection (branching on a condition, e.g. if/else) and iteration (repeating a block, e.g. for and while loops).
- What is modularity, and which computational thinking step does it express?
- Breaking a program into functions or procedures with defined inputs and outputs, making it easier to build, test and understand. It is the programming form of decomposition.
- Normal, boundary and erroneous test data
- Normal: typical, expected values. Boundary: values at the very edge of what is valid. Erroneous: invalid values the program should reject or handle gracefully.
- What is debugging by tracing?
- Stepping through code line by line, recording variable values, to find where the actual behaviour diverges from the expected behaviour.
- Name four primitive data types
- Integer, real (float), Boolean and character or string.
- What kinds of question does Paper 2 ask on programming?
- Code reading (predicting the output of code or pseudocode), code writing (a short program or function to a specification) and finding or fixing errors, answered in Java or Python.
- Class vs object
- A class is a template defining the attributes (data) and methods (behaviour) of a type of object. An object is one instance of a class, with its own attribute values.
- What is a constructor?
- A special method that runs when an object is created (instantiated) and sets its initial attribute values.
- What is encapsulation?
- Bundling data with the methods that act on it and hiding the data from outside the class, usually with private attributes accessed through public methods (getters and setters).
- What is inheritance?
- A subclass takes on the attributes and methods of a superclass and can add its own or override them, so tested code is reused.
- What is polymorphism?
- The same method name behaving differently depending on the object it is called on, e.g. a subclass overriding a superclass method.
- What does a UML class diagram show?
- Each class as a box with its name, attributes and methods, with visibility marks (+ public, − private), and lines showing relationships such as inheritance between classes.
- What is an abstract data type?
- A data type defined by its values and the operations allowed on it, not by how it is implemented. B.4 is HL only.
- What is a linked list?
- A dynamic structure of nodes, each holding data and a pointer to the next node; the last points to null. Nodes can be added or removed by changing pointers, without shifting other items.
- Singly vs doubly vs circular linked lists
- Singly: each node points to the next. Doubly: each node points to the next and the previous. Circular: the last node points back to the first.
- What is a binary search tree?
- A binary tree in which each node's left subtree holds smaller values and its right subtree larger values, so a search can discard half the remaining tree at each step when it is balanced.
- What is a set as an abstract data type?
- An unordered collection of distinct values, with no duplicates, supporting operations such as add, remove, membership test, union and intersection.
- What is a hash table, and what is a collision?
- A structure that uses a hash function to turn a key into the position where its value is stored, giving very fast look-up. A collision is when two keys hash to the same position.
Flashcards by topic
- Topic 1 Theme A – Concepts of computer science 26 cards · 4 subtopics
- Topic 2 Theme B – Computational thinking and problem-solving 24 cards · 4 subtopics
Written for International Baccalaureate Diploma Programme Computer Science, (First assessment 2027).
Cards by Marlbridge Academic Team. This deck has not yet been reviewed as a whole by a subject teacher. Report an error.