Revisionโ€บOCR A Levelโ€บElements of Computational Thinking
OCR A Level H446 ยท Topic 2.1

Elements of Computational Thinking

62 practice questions

Practice Questions

62 questions

What are the four key components of computational thinking?

easy

How does decomposition help in large software projects?

easy

Explain how decomposition applies when building a school management system.

medium

Why is it useful to identify reusable components when decomposing a problem?

medium

Which of the following best defines 'decomposition' in computational thinking?

easy

Explain the relationship between decomposition and top-down design.

medium

Which of the following is NOT typically considered a benefit of decomposing a problem before solving it?

medium

A team is asked to build a quiz application. Suggest three sub-problems the overall problem could be decomposed into.

medium

Which type of diagram is commonly used to show how a problem has been decomposed into modules and sub-modules?

easy

Explain how decomposing a program into smaller modules can make debugging easier.

medium

Give an example of abstraction in a real computing context.

medium

What is a computational model?

medium

Which of the following is the best example of abstraction?

medium

What is memoisation and how does it relate to abstraction?

hard

A mapping app models a city as a graph: junctions are nodes, and roads are edges with weights representing travel time. Explain how this is an example of abstraction.

medium

In computational thinking, a 'model' is best described as:

easy

Explain the difference between abstraction and decomposition, even though both involve simplifying a problem.

medium

An operating system provides a simple 'save file' function, hiding the complex details of how data is physically written to a hard drive's sectors and tracks. This is an example of:

medium

Explain the difference between procedural abstraction and data abstraction, giving an example of each.

hard

A weather forecasting program uses a simplified mathematical representation of the atmosphere, ignoring minor factors that have little effect on the outcome, to predict tomorrow's weather. This is best described as:

medium

Explain what "thinking procedurally" means.

medium

What is the difference between concurrent and parallel execution?

hard

What is meant by "thinking logically" in computational thinking?

easy

What is the Halting Problem and why is it significant?

hard

Give two features that distinguish tractable from intractable problems.

hard

Which type of computational thinking involves identifying the inputs, outputs, and any constraints of a problem before designing a solution?

easy

What is meant by "thinking procedurally" when solving a problem?

medium

Explain what "concurrent thinking" means and give an example of a real-world system where it is important.

hard

A programmer caches the results of a slow database query so repeated requests for the same data are answered instantly. Which element of computational thinking does this best demonstrate?

medium

What is meant by "thinking logically" in computational thinking?

easy

A queue management system at a supermarket must handle customers being served at multiple checkouts at the same time, and a self-checkout being temporarily out of service. Identify which computational thinking technique addresses each scenario.

hard

Explain why "thinking ahead" includes considering how a solution will cope with larger amounts of data in the future.

medium

What is pattern recognition in computational thinking?

easy

How is pattern recognition applied in image recognition?

medium

Explain the difference between decomposition and pattern recognition, using a real-world example for each.

medium

Explain how recognising patterns between a new problem and previously solved problems can help when designing an algorithm.

medium

An email program automatically identifies messages as 'spam' based on common features shared with previously identified spam messages (e.g. certain words, sender patterns). This is an example of:

medium

A programmer needs to arrange a list of student records by exam score. Explain how recognising this as a 'sorting' problem helps them solve it.

medium

Which of the following is the best example of pattern recognition in everyday computing?

easy

Explain how recognising that a problem is a 'graph traversal' problem (such as finding a route between two locations) can help a programmer design a solution.

hard

What is the key difference between pattern recognition and abstraction in computational thinking?

medium

Discuss how pattern recognition might be used by a streaming service to recommend films to a user.

medium

What is a heuristic algorithm and when is one used?

hard

Describe, using the example of solving a maze, what is meant by 'backtracking' as a problem-solving strategy.

medium

Backtracking is best described as a strategy that:

easy

A program is trying to place numbers 1-3 in a row such that no two adjacent numbers are the same, as part of a previous failed attempt. Explain, step by step, how a backtracking algorithm might explore placing values into the first two positions if placing 1,1 fails the constraint.

hard

Which of the following problems is most commonly associated with being solved using a backtracking algorithm?

medium

Explain how backtracking differs from a simple 'brute force' approach that tries every possible combination.

medium

Backtracking algorithms are often naturally implemented using which programming technique/structure, due to the need to 'undo' choices and return to a previous state?

medium

Explain why backtracking algorithms can become very inefficient for large problems.

medium

While solving a maze using backtracking, a program reaches a junction with three possible paths. It follows the first path, which leads to a dead end. What does the program do next?

medium

Describe a real-world (non-maze) example of a situation where 'backtracking-style' thinking โ€” trying an option and undoing it if it does not work โ€” could be applied.

medium

Explain what is meant by 'data mining'.

medium

What is the main purpose of data mining?

easy

A supermarket analyses data from customer loyalty cards to find that customers who buy nappies often also buy beer. Explain how this is an example of data mining, and how the supermarket might use this information.

medium

Which of the following techniques is commonly used in data mining to group similar items or customers together based on shared characteristics?

medium

Discuss one ethical concern raised by organisations using data mining on customer data.

hard

What is the key difference between routine 'data processing' (e.g. updating a customer's address) and 'data mining'?

medium

Explain what is meant by 'market basket analysis' and how it relates to data mining.

medium

Which of the following industries commonly uses data mining to analyse customer behaviour and improve services?

easy

Explain the role of 'big data' in enabling modern data mining techniques.

hard

A bank uses data mining on transaction data to identify unusual spending patterns that may indicate stolen card details. This is an example of using data mining for:

medium

Revision Notes

Thinking Abstractly

Abstraction

Removing unnecessary detail so only what matters for the solution remains. Representational abstraction builds a simplified model of reality; abstraction by generalisation groups things by shared characteristics so one solution handles many cases. A London Underground map is an abstraction โ€” connections and order of stops matter; real distances, road layout and scenery do not.

Why abstraction is essential:Real problems contain far too much detail to solve directly. Abstraction produces a manageable model, lets one solution apply to a whole class of problems, and hides complexity behind clean interfaces so layers can be built and changed independently.

Layers of abstraction

Computing is built from stacked abstractions: a programmer uses a high-level language without thinking about machine code; the language uses the OS without thinking about the hardware; the hardware uses logic gates without thinking about electrons. Each layer trusts the one below to "just work".

๐Ÿ’ก For "explain the role of abstraction in this scenario", identify exactly what detail is being removed and WHY removing it makes the problem solvable or the model reusable.

Thinking Ahead

Inputs, outputs & preconditions:Before designing a solution, identify the data needed (inputs), the results required (outputs), and the preconditions that must hold for the solution to work โ€” e.g. binary search has the precondition that the list is already sorted.
Reusable components:Plan to use existing, tested components (libraries, functions, classes) rather than rewriting. This saves time, reduces bugs, and means improvements to the component benefit everywhere it is used.
Caching:Storing the results of expensive or frequently-needed operations so future requests are served instantly. Examples: a browser cache stores web resources; memoisation caches function results; a CPU cache stores recently used memory. The trade-off is memory use and keeping the cache up to date (cache invalidation).
๐Ÿ’ก "Identify the preconditions of this algorithm" means state exactly what must be true BEFORE it runs for it to produce a correct result (e.g. "the array is sorted in ascending order", "the divisor is non-zero").

Thinking Procedurally & Logically

Thinking procedurally

Decomposition breaks a large problem into smaller sub-problems that can be solved independently. A top-down / modular design refines the problem into modules, each as a subroutine, then combines them. Benefits: work can be shared across a team, modules are reusable and individually testable, and the structure is easier to understand and maintain.

Thinking logically

Identify the points in a problem where a decision must be made, the condition that drives each decision, and how each outcome changes the flow of the solution. Clear logical structure (sequence, selection, iteration) is what makes an algorithm correct, predictable and traceable.

Decomposition example
Problem: build a quiz app
  - display a question      (module)
  - read and store the answer (module)
  - check the answer / score  (module)
  - move to the next question (module)
  - show the final result     (module)
Each module is designed, coded and tested on its own,
then assembled โ€” top-down design.
๐Ÿ’ก A modular answer scores well: state that decomposition lets a team work in parallel, makes each part testable in isolation, and produces reusable subroutines.

Thinking Concurrently

Concurrent processing:Carrying out more than one task in overlapping time periods. On a single core this is achieved by time-slicing (rapidly switching between tasks so they appear simultaneous); on multiple cores tasks genuinely execute in parallel.

Benefits and drawbacks

Concurrency can reduce total run time for tasks that split into independent parts, and keeps a program responsive (e.g. the user interface stays usable while a download runs in the background). Drawbacks: not all problems can be split; results from separate parts may need recombining; and shared data must be synchronised to avoid race conditions (where the result depends on unpredictable timing) โ€” adding complexity and overhead.

Where concurrency helps vs not
HELPS: downloading 10 independent files
  โ†’ 10 tasks run at once, finishing far sooner.
DOES NOT HELP: computing the 100th Fibonacci number
  by the simple recurrence
  โ†’ each value needs the previous one, so the steps
    must run in order โ€” no parallelism possible.
โš ๏ธ Common mistake: Concurrent does not automatically mean faster. If the task is inherently sequential, or the overhead of creating and coordinating tasks (and locking shared data) outweighs the work, concurrency can be slower.