The Lab
Interactive exhibits for GCSE & A-Level Computer Science: watch algorithms think, explore the concepts behind them, and see how a computer actually works.
Watch
1The big picture, on video
- GCSEA-LevelBoolean logic & logic gatesAND · OR · NOT · NAND · NOR · XOR · XNORToggle inputs, watch signals flow, build circuits from 2 to 4 gates
- GCSEA-LevelBoolean Logic: The Hardware of AIAND · OR · NOT · the phone unlock · the fire alarm · the login challengeUnlock a phone with an AND gate, then watch a face model's score cross a threshold and become the single bit the gate can read
- GCSEA-LevelWhat the columns are worthPlace value · counting in hexadecimal · FF is not 30 · 256 values, largest 255 · four bits per hex digit · hex colour codesWatch 9 roll over into 10 and F roll over into 10, find out why FF is 255 and not 30, and count the 256 values a byte can hold
- GCSEA-LevelBinary & hexadecimalBits, nibbles, overflow, pixels and soundFlip bits and watch every representation update
- GCSEA-LevelCarry the oneBinary addition · the travelling carry · overflow · two’s complement · subtractionAdd two binary numbers one column at a time and watch the carry travel, then find the column where the carry has nowhere to go, then take a number away by adding its two’s complement through the very same columns
- GCSEA-LevelBinary Shifts: Multiply and DivideLeft shift × 2ⁿ · right shift ÷ 2ⁿ · overflow · underflow · 20 questionsShift an 8-bit register and watch the arithmetic hold, then watch it break: a 1 bit off the left end makes the answer wrong, and a 1 bit off the right end only makes it rounded down
- GCSEA-LevelMixing lightRed, green and blue light · hex colour codes · 24 bits a pixel · uncompressed file sizesMix three lights with sliders, turn any colour into its hex code and its 24 bits, and work out how much space an uncompressed picture needs
- GCSEA-LevelCatching a soundSamples · sample rate · bit depth · uncompressed file sizes · MP3 and lossy compressionMeasure a sound the way a picture is measured, choose how often and how finely, work out what it costs to store, and see what MP3 throws away
- GCSEA-LevelSqueeze itCompression · runs of the same colour · merging colours · dictionary codingShrink a 16×16 icon, then find out which compression gives every pixel back
- GCSEA-LevelThe memory hierarchyRegisters → cache → RAM → secondary storageFollow the data, then switch the power off
- GCSEA-LevelLinked listsSingly and doubly linked · the pointer chase · insertion · deletionChase pointers from Head, count every hop, and rewire a list without moving a single node
- GCSEA-LevelChoose the structureData structures · the printer spool · the undo history · the fixed record · the playlistRun the same jobs through different structures and see which one the task actually needs
- GCSEA-LevelChoose the algorithmSorting and searching · which algorithm? · which search?Run three sorts and two searches on fixed lists, and count the work each one really does
- GCSEA-LevelThe fetch–decode–execute cyclePC · MAR · MDR · CIR · Accumulator · CU · ALUWatch one instruction travel the whole machine, step by step
- GCSEA-LevelSame chip, different jobEmbedded systems · one job, fixed program · many jobs, one processor · close the valve in timeTry to install an app on a washing machine, then race it against a busy laptop to close a valve in time
- GCSEA-LevelFollow the lineRobotics · sense, think, act · open loop or closed loop · when a sensor liesWrite a line-following robot's rules, flatten its battery and break a sensor, and watch what it can and cannot know
- GCSEA-LevelNetworkingFollow a packet from client to serverSwitches, routers, IPs and MACs on one journey
- GCSEA-LevelEnvelopes all the way downProtocol layers · what each device reads · skip a layerWrap one request layer by layer, and watch the router read only two of its headers
- GCSEA-LevelCybersecurityCipher · hashing · brute force · firewall · phishingFive safe, hands-on security simulations
- GCSEA-LevelThe name boxSQL injection · where the string ends · a value, never codeType into a school's search box and watch one quote mark turn a name into SQL
- GCSEA-LevelRule or learned?Machine learning · a written rule against a trained model · how many neighbours · only red applesSort apples from pears with a rule, then with a model that learns from examples, and watch what its examples teach it
- gcseFibonacci in NatureOne sequence hides in flowers, sunflowers and rabbitsEnrichment · links to OCR A Level 7.1 (recursion)
Data Structures
7See all →How data is actually stored and organised: types, arrays, lists, stacks, queues, sets, dictionaries
- GCSEA-LevelIntegers & floating pointMantissa · exponent · normalisation · precision lossWatch 0.1 + 0.2 fail to equal 0.3, and find out exactly why
- GCSEA-LevelStringsIndexing · length · slicing · methods · searching · traversalType your own string and take it apart: the slicer shows you the character a slice leaves out
- GCSEA-LevelArrays, linked lists & Python listsData types → arrays → linked lists → Python lists → comparisonDelete from the front and watch four elements shift. Then delete from the end and watch nothing move
- GCSEA-LevelTuplesImmutability · packing & unpacking · tuple vs listTry to change an element and watch the attempt fail
- GCSEA-LevelSetsUniqueness · membership · union · intersection · differenceDrag values between two circles and watch the operations answer live
- GCSEA-LevelStacks & queuesLIFO · FIFO · push/pop · enqueue/dequeue · peekDrive the operations yourself and watch which end each value leaves from
- GCSEA-LevelDictionaries & hash tablesKey–value pairs · hashing · collisions · chaining · linear probingDrag a key at a bucket and watch the hash function put it somewhere else entirely
Programming
6See all →How a program is built and controlled: the three constructs, loops, and surviving bad input
- GCSEA-LevelSequence, selection & iterationThe three constructs · trace tables · if / elif / elseStep through a program line by line and watch the trace table fill in as it runs
- GCSEA-LevelFor loops & while loopsCount-controlled · condition-controlled · range() · infinite loopsDrag the range sliders and watch the excluded stop value struck through
- GCSEA-LevelSwapping two valuesAssignment is one-way · save before you overwrite · the temp variableTry to swap two colours with two pours, and watch what the drain collects
- GCSEA-LevelHandling errorsTracebacks · try / except · validation loops · which error, and whenWatch a program stop dead, then watch the same one survive the same bad input
- GCSEA-LevelObjects and classesOne plan, many objects · attributes · inheritance · polymorphismMake objects from one class, change one of them, then watch the same line of code run different methods
- GCSEA-LevelEncapsulationMinus five hundred · public or private · who can refuse a changeTry to set a bank balance to minus five hundred, once through an open door and once through a method that can say no
Misconceptions
12See all →The ideas students reliably get wrong, set up so the wrong answer fails visibly
- GCSEA-LevelMisconceptions: Data RepresentationBits and colours · bit rate · encoding or encryptionPredict how many colours 4 bits gives, then watch the palette get built
- GCSEA-LevelMisconceptions: ProgrammingAssignment · where a while loop stops · when an if is checkedA photocopier, a loop gate and a timeline, each set up to refuse the wrong idea
- GCSEA-LevelMisconceptions: Robust ProgramsValidation or verification · test coverage · black-box testingRegister a false age with every check showing green, then find out what testing needs
- GCSEA-LevelMisconceptions: Languages & TranslatorsWhat the CPU can read · imperative or declarative · when a translator is neededSend Python straight at a CPU and watch the decode unit search its whole table and find nothing
- GCSEA-LevelMisconceptions: AlgorithmsPairwise comparison · pivot choice · syntax or logicFind the smallest with the cards face down, and see why sorting costs what it does
- GCSEA-LevelMisconceptions: ArchitectureVirtual memory · cache vs registers · clock speedThree things nearly everyone gets wrong. Try the wrong answer and watch why it fails
- GCSEA-LevelMisconceptions: LogicGate arity · voltage or binary · AND or ORTry to wire a second input into a NOT gate and find there is nowhere to put it
- GCSEA-LevelMisconceptions: System SoftwareApplications, utilities and the OS · where the OS lives · maker or OSSort software with three questions instead of three lists, then try to fit an OS into a ROM chip
- GCSEA-LevelMisconceptions: NetworksInternet or WWW · browser or search engine · topology or service modelCut a cable and watch the traffic reroute, then isolate a host and watch one service go dark
- GCSEA-LevelMisconceptions: SecurityDDoS and the CIA triad · the padlock · encryption backdoorsFlood the server, then click the safe and find it untouched
- GCSEA-LevelMisconceptions: Issues & ImpactsWhich law · which kind of issue · the digital divideFile a case in the wrong law book and watch which of its conditions fails
- GCSEA-LevelMisconceptions: DatabasesDatabase or spreadsheet · SQL · keys · JOINs · normalisationA relational playground where the queries really evaluate and the anomalies really break the data
Sorting
4Watch lists order themselves, pass by pass
- gcseBubble SortCompare neighbours, swap if out of order, repeat until a pass makes no swapsOCR GCSE 2.1 · A Level 8.1 & 8.2
- gcseInsertion SortTake the next value and slide it left into the sorted sectionOCR GCSE 2.1 · A Level 8.1 & 8.2
- gcseMerge SortSplit until single values, then merge the halves back in orderOCR GCSE 2.1 · A Level 8.1 & 8.2
- alevelQuick SortPick a pivot, partition around it, recurse: the exam's favourite average-vs-worst contrastOCR A Level 8.1 & 8.2
Searching
2Hunt for a target, one comparison at a time
Graphs & paths
1Nodes, weighted edges, and the cheapest route
Trees
1Traversals, pointers, and the sorted-order trick
Recursion
1Call stacks that grow, wait, and unwind