Show Menu

A-Level Computing Key - Terms & Concepts Cheat Sheet by

A-Level Computing Key - Terms & Concepts Cheat Sheet - for OCR A-Level (2017 Spec)

Compon­ent­s/P­roc­essor Registers

The central interface for all the components of a PC. Everything connects to the mother­board via slots, wires, readouts and connec­tors.
Processor (CPU)
A combin­ation of registers than manipulate data between the registers. The speed of a processor is measured in the number of instru­ctions it can complete per second (Hz). Modern computers speed is measured in GHz.
Secondary Storage
Used to store programs and data. It can be partit­ioned to allow for dual-b­ooting multiple operating systems.
Processor Structure
Arithmetic Logic Unit (ALU)
The ALU carries out arithmetic calcul­ations and compar­isons. The result of any calcul­ation is sent to the Accumu­lator
Control Unit (CU)
The CU controls the operation of the hardware, inc. input and output devices, it controls the Fetch-­Dec­ode­-Ex­ecute cycle.
The clock is the part that regulates the cycle of the CPU. It provides a regular pulse of high voltage then low voltage. This high-low transition is a cycle, each cycle is an instru­ction
Program Counter (PC)
This register holds the address of the next instru­ction to be executed, the PC is automa­tically implem­ented to the next instru­ction, unless the previous instru­ction was a jump.
Memory Buffer Register (MBR)
Values fetched from memory are sent to MBR.
Memory Address Register (MAR)
The location in memory of the current instru­cti­on/data being fetched.
Current Instru­ction Register (CIR)
The instru­ction currently being execut­ed/­decoded
Data Bus
Carries the data between memory and the MBR
Address Bus
Carries the memory location of the instru­cti­ons­/data being received.
Control Bus
A bus with 2 states, set or enable, which govern if the data bus is reading or writing to memory
Fetch Decode Execute
The PC contents are copied to the MAR
Instruction at address in MAR MBR

Instruction is decoded into:
1. Operand The data to preform an instru­ction on
2. Op-Code The instruction

Instruction executed
If data is being committed to memory, its held in the MBR
Cycle repeats until stop instru­ction
Factors affecting Processor Perfor­mance
Multiple Cores
The increase in number of cores, allows for a greater throughput of data. If the software is threaded - can use multiple cores - it will divide up tasks to the different cores. However, it must be coded in, else it will use the single core.
Cache Size
Cache is a small amount of very fast memory. Repeatedly used instru­ctions and data is stored in the cache for quick access. The bigger the cache, the more can be stored on it thus reducing processing time
Clock Speed
The clock regulates the instru­ction execution rate. The faster the clock, the more cycles completed per second.
Where the stages of the F-D-E cycle are 'stacked' so that they can be processed at the same time. While one instru­ction is being fetched, the previous is being decoded. This may not necess­arily increase processing time but throughput is increased.

• If an instru­ction requires the result of a previous instru­ction, the CPU will remain dormant leading to 'bubbl­es'­/pi­peline stalls in the pipeline.
• Jumps lead to the pipeline having to be flushed due to the change in instructions

Hyper-­Thr­eading Where the CPU is intell­igent enough to fill the bubbles caused by pipeline stalls with other non-de­pendant instru­ctions from separate threads.
Processor Archit­ecture
The Von-Ne­umann archit­ecture is commonly used in most PCs. It stores both programs and data in the same memory. Using the F-D-E cycle, it carries out a single instru­ction at a time.

+ More Robust than Harvard (older)
+ Single Storage

- Each Instru­ction takes 2 cycles (fetch­/decode and execute)
- Cannot implement pipelining
The Harvard archit­ecture stores programs and data in separate memory and uses the control unit at the centre of the structure. Generally used in embedded systems.

+ Can complete an instru­ction in a single clock cycle (assuming pipelining is used)
+ Modern
+ Can implement pipelining

- Separate Memory
CISC (Complex Instru­ction Set Computing)

• One instru­ction can complete an entire sequence - more complex
• Higher Power Consumption
• Powerful
• Generates more heat
RISC (Reduced Instru­ction Set Computing)

• Only one value fetche­d/s­tored per instru­ction cycle
• Less Power Required
• Used in smaller devices (Smartphones)
• Generates less heat - requires less cooling methods
Flynn's Taxonomy
Single Instru­ction, Single Data-s­tream
Single Core CPUs

• No parallelism
• Single CU, fetches single instru­ction
Single Instru­ction, Multiple Data-s­treams

• One instru­ction preformed on many data-streams
• Naturally parall­elised operations
• Examples: Fractal Rendering, Graphics Processing (hence GPUs) - each pixel is indepe­ndant
Multiple Instru­ctions, Multiple Data-s­treams
Multi-core CPUs

• Multiple autonomous processors simult­ane­ously executing different instru­ctions on different data
• Uses either one shared memory space or a distri­buted memory space.

Software Generation

Specific Applic­ation
A piece of software that has a specific purpose, such as order entry, payroll, stock management etc. It may be Bespoke (made to order) or Off-th­e-shelf (designed to be used in a variety of situat­ions).
General Purpose Applic­ation
An applic­ation that allows the user to produce their own solution to a problem. Most are sold as a package/a license.
• Word Processing
• Desktop Publishing
• Spreadsheets
• Database Management
• Presen­tation Software

Specific Examples
• Microsoft Office
• Adobe Suite
Open Source vs. Closed Source
Open Source Source code is readable to anybody and freely modifiable.
Closed Source Executable only, source code is kept hidden.

Pros of OS
• Free (usually)
• Community Coding/Bug Fixing - Usually faster than any closed-source
• Customisable
• Freedom to do what you like

Pros of CS
• Profes­sional Develo­pment
• Lower security risks
• Well documented and customer support

Translator Software
Software that convert one progra­mming language into another. There are 3 catago­ries: Compilers, Interp­reters and Assemb­lers.

Assemblers Convert Assembly into machine specific machine code. Assembly language consists of mnemonics that represent different instru­ctions. It is converted to binary (machine code)

Interp­reters Checks and executes code line by line.

Compiler Checks all the codes syntax, semantics and logic and then converts the code into Object code (usually machine code or similar low-le­vel). The compiled code is usually what is distri­buted.
Stages of Compil­ation
Lexical Analysis
Firstly the code is striped of anything uneeded such as comments and redundant whitespace

The code is then divided into Lexemes (the smallest 'unit' of code).

Tokens are then assigned to each lexeme indicating what it is. Some token examples:
• Identi­fiers - for variables, subrou­tines, classes etc.
• Keywords - new, if, for, while etc.
• Operators - +, - , / , == etc.
• Literals - fixed numbers and strings
• Symbols - {}, (), ; etc.

Errors are caused when a lexeme cannot be assigned a token
Syntax Analysis
The stream of tokens generated is then analysed to check they match the rules of the language. Tree data structures are often used in this process.

An example of valid syntax would be:

String word = "­Hello, World!";
Datatype Literal Operator String­Literal Symbol

Errors occur when a series of tokens cannot be matched to a rule, such as multiple datatypes.
Semmantic Analysis
The stage where code is checked for logical errors. For example:
• Datatype mismatch - assigning a String to an int
• Undeclared Variables, or out of scope variables
• Multiple variable declarations
• Array out of bounds with an integer literal.

Errors occur when one of the rules are broken. NB Not all semantic errors can be caught during compil­ation. For example accessing an array with a integer variable is logically fine, but the integer value may be out of bounds causing a run-time error.
Interm­ediate Code Genera­tio­n/O­pti­mis­ation
The code is then converted into interm­ediate code (Java to Java bytecode, where it remains until use - not all languages do this)

Interm­ediate code is machine indepe­ndent

The code is then optimised, so that it runs faster and requires less resources, but still having the same output.
Machine Code Genera­tio­n/O­pti­mis­ation
The final stage of compil­ation is the conversion to machine code. This process has to be repeated for each processor as it is machine dependant. Specific optimi­sations are also done on the separate processors as code that works well with one instru­ction set may not work as well with another.

Libraries, Linkers and Loaders

Library Generic name for a collection of programs used in develo­pment. Some languages have native ones. Saves time as the developers don't have to create their own code.
Linker Combines object and library files
Loader Loads the object code into memory to be executed

Testing Strategies

Black Box (Alpha)
Testing that examines the functi­onality of a applic­ation, without looking at its internal code/s­tru­ctures.
White Box
Tests the internal struct­ure­/wo­rkings of a applic­ation rather than its functi­onality (opposite of black box)
Top Down
Testing of modules and sections of code that aren't yet implement. Testing the behaviour between modules.
Top Down
Testing of modules and sections of code that aren't yet implement. Testing the behaviour between modules.
Bottom Up
Testing each part of the applic­ation indivi­dually then testing the parts that rely on the sectio­n/m­odule.
Usability (Beta)
Testing how easy a system is to use by testing it with real users. It shows how somebody without a working knowledge of the applic­ation would use the system and any problems they might find.
Test Data
A range of test data must be used to properly test a system. It should include:
• Normal Data
• Boundary Data
• Standard Incorrect Data - incorrect data that could easily be entered
• Standard invalid data - e.g. text into numeric fields
• Extreme data - data that would never be entered normally, used to test the limits of a system


A 'bluep­rint', a combin­ation of attributes and methods that create an object.
An instance of a class.
Where attributes and methods are wrapped in their objects. Access modifiers control how the methods and the attributes can be accessed, whether that be by any class, or only within its own class.
A relati­onship among classes where a child class shares method­s/a­ttr­ibutes with its parent class. The child classes can also have their own indepe­ndent attrib­ute­s/m­ethods but all child nodes share the ones inherited from the parent.
Abstract Class
A class which contains attributes and methods like a normal class, but the class itself cannot be instan­tiated. An example is an Animal, you can write an abstract class, but you cannot create just an Animal.
A feature of a progra­mming language that allows routines to use variables of different types at different times. For example, overlo­ading constr­uctors which behave differ­ently depending on their parameters

Web Techno­logies

HTML (Hypertext Markup Language)
The standard language for displaying webpages. A HTML document starts with
<!DOCTYPE html>

It consists of tags which are opened and closed <ta­g><­/ta­g>. Each document has a head and a body.
<a href="h­ttp­://­www.go­ogl­e.c­om">Link Text</­a>
<img scr="pa­th/­to/­ima­ge.j­pg­" alt="pi­ctu­re">
<p>­Normal Paragraph text</­p>
CSS (Cascading Style Sheet)
The standard way to style webpages, whether internal or extern­alised. Extern­alised styles­heets allow developers to keep design and content completely separate.
JS (JavaS­cript)
JS is an interp­reted code that adds intera­ctivity to websites. It works on virtually all hardware and is used on nearly all websites. For example there are currently 300,000 JS repos on Github, Java has 200k
Search Engine Indexing
A search engine searches through webpages, for certain keywords and phrases. Problem Indexes are used, when a new document (webpage) is added, the words/­phrases are tokenised, and added to the list.
PageRank Algorithm
Google's algorithm that calculates the weighting of webpages. All pages have an initial rank, but for each link, it gives a certain amount to the webpage linked. Other algorithms are also used to give pages different rankings depending on what the user is searching for.
Client­-Side Processing
Processing preformed in the browser, usually JS. This allows user entered data to be checked before sending it to the server, which reduces the load on the server. For example, ensuring an email has an @, or a password is a certain number of charac­ters. Anybody can view the code for client­-side proces­sing, so its best for just verifi­cation
Server­-Side Processing
Processing performed on the server. The code is only viewable to people with access to the server­-files. It processes requests and serves a webpage based on the requests

L.O.R. (*) Questions

Data Protection Act
8 Principles:
1. Personal data must be obtained lawfully and fairly
2. P.D. must be held for a specified purpose
3. P.D. must be adequate, relevent and not excessive
4. P.D. must be kept up-to-date and accurate
5. P.D. must not be kept longer than necessary
6. P.D. must be processed in accordance with data subjects rights
7. P.D. must be kept securely
8. P.D. must not be transf­erred outside the EU without permission
Computer Misuse Act
Level 1: Unauth­orised Access
• Accessing secure parts of a computer, that they are unauth­orised to access
• In organi­sat­ions, accessing secure parts that are beyond your rights.

Level 2: Unauth­orised Access with intent to commit a Crime
• Level 1 + intent to commit another crime.

Level 3: Unauth­orised Modifi­cation
Includes intent to:
• Impair the operation of any PC
• Prevent or hinder access to a program
• Impair the operation of any program or reliab­ility of data.
Copyright, Designs & Patents Act
Protects indivi­dua­ls/­org­ani­sations intell­ectual data. It protects:
• Income for the authors - Allows the author to license the data.
• Cost of creating the product - some products can cost thousands to produce
• Quality of Produce - pirates often alter products to bypass security
• Alteration Protection - Altering programs can have unintended aftere­ffects.
Regulation of Invest­igatory Powers Act
This act allows government agencies, to request access to secure inform­ation. It makes provisions for:
• Interc­eption of communication
• Acquis­ition and disclosure of data
• Surveillance
• Access to electronic data protected by encryp­tion.
Moral/­Eth­ica­l/S­ocial Issues
Computers in the Workplace
• Big Brother concern - an employer could watch over employees
• Reduced Produc­tivity - employees can do multiple things at once, which may reduce produc­tivity as employees may 'waste' time
Automated Decision Making
Computers are starting to have the ability to make decisions based on input data. Usually it can be better than any human making the same decision. The issue is what happens when the wrong decision is made, who is to blame?
This is the one of the biggest issues, as AI use is rising among recent years. The issues are the same as automated decision making, but more issues arise when you consider cognit­ive­/when is a computer considered alive?
The increase in use of computers = more RAW materials Another issue is the disposal of old parts/­dev­ices.
Moral concerns are raised at whether the internet should be censored, would it be restri­cting the freedom of inform­ation. The issues arise when consid­ering adult content, and piracy.
Monitoring Behaviour
It is possible to monitor what indivi­duals are using a computer for, there is a moral issue when consid­ering how much should an individual be monitored, and the issues based on a persons privacy.
Personal Inform­ation
Rises a privacy concern. Computers can now monitor peoples inform­ation and collect it. When does this become a breach of privacy.
Breaking the law (C.D.P.) but people do it anyway.
Offensive Material
Computers are general purpose, what people do with them can be considered offens­ive­/mo­rally wrong e.g. cyberb­ull­ying, which can have drastic effects

Data Structures

A data structure used to whole elements of the same data type.
1D Array
An Array with a single dimension, i.e. it only has a given length
2D Array
An array with 2 dimens­ions. It is commonly used to represent coordi­nates or a table, with the indexes relating to rows/c­olumns
3D Array
An array with 3 dimens­ions. It is used for repres­enting 3D space so is also used for coordi­nates a lot.
Linked List
A data structure where each element in the list points to the next one. This makes is very easy to add/re­mov­e/r­eorder elements as only the pointer needs to change each time.
A First In, First Out (FIFO) data structure.
When coding a queue, there must be the possib­ility to:
• Check if the queue is full
• Read/R­emo­ve/­Return an element from the front of the Q
• Place a new element at the end of the Q
Circular Queue
The end of a queue linking back to the beginning.
A First In, Last Out (FILO) data structure.
When coding a stack, there must be the possib­ility to:
• Check if the stack is full/empty
• Read/R­emo­ve/­Return an element from the top of the stack (pop)
• Add a new value to the top of the stack (push)
A set of nodes/­ver­tices connected by edges.
A graph where the edges have a direction.
Bi-Dir­ect­ional Graph
A graph where the edges have 2 way direct­ions.
A tree is a simple un-dir­ected graph which contains no loops. A tree has a root where all other nodes/­edges originate from
Binary Tree
A tree where each node has a maximum of 2 sub-nodes. Nodes with no child nodes are called leafs, and the edges, branches.
Hash Table
A table where the index system is the data the person is looking for, but


Input Device
A device (piece of computer hardware equipment) that is used to provide data and control signals to an inform­ation processing system such as a computer or inform­ation appliance. Examples of input devices include keyboards, mouse, scanners, digital cameras and joysticks.
Output Device
is any device used to send data from a computer to another device or user. Most computer data output that is meant for humans is in the form of audio or video. Examples include monitors, projec­tors, speakers, headphones and printers.
Inform­ation is held in blocks consisting of tracks and sectors. Each block contains the same amount of inform­ation, therefore inform­ation is more dense closer to the centre.

Rotation Speed
• A HDD consists of a very fast spinning disk (5400 - 7200 rpm)
• A reading head is suspended above the disk due to the Bernoulli effect
• Due to fast speeds, the housing has to be evacuated

Capacity vs Cost
• Largest HDD avaliable ~ 12TB.
• Roughly 3p per GB. (£0.00­000­000­0027915 per Byte)
A storage medium that has no moving parts. It uses a data controller to control the read/write of data. 2 rules of the data controller:
1. You can combine pages to form a block, but a block cannot overwrite individual pages
2. Before writing to a memory location, the page previously allocated must be erased.

• Low Latency Time
• Fast Transfer speed

• More Expensive

Capacity vs Cost
• Largest: ~4TB
• Roughly 30p per GB (£0.00­000­000­0291625 per Byte)
A storage medium that uses binary pits to encode data. A laser is beamed at the disk and uses the diffra­ction of the light to detect a 0/1 (troug­h/p­eak).

Read-only: A laser is used to burn the disks, the data cannot be changed
Re-Wri­table: A dye is used where if a high temp is used, it will go opaque (creating a peak - 1) and if a higher temp is used it goes transp­arent (a trough - 0). The disk is now reusable.
Solid State: 200 to 2500 MB/s
Hard-Drive: 1030 MB/s
Optical (x1 Speeds):
- Blue-ray: 4.29 MB/s
- DVD: 1.32 MB/s
- CD: 0.15 MB/s
The 'working' area of the computer. Programs and data currently in use is stored in the RAM. On startup the BIOS loads the OS into the RAM.

• Random Access - allows data items to be read or written in almost the same amount of time irresp­ective of the physical location of data inside the memory.
Volatile emptied on power down
• ~1-16GB
A permanent area of storage. The contents cannot be altered by software. Contents of ROM is written at manufa­cture

• Read-Only Access
Non-Vo­latile retains data at power down
• Mainly used to store firmware or applic­ation software in plug-in cartridges.
• ~4MB
• Examples of ROM: Bootloader (BIOS/­UEFI),

Basic Input Output System­/Un­ified Extensible Firmware Interface The BIOS is preforms the hardware initia­lis­ation during the bootup, and provides runtime services between the OS and hardware. UEFI was designed to be the successor to the BIOS
Virtual Memory
When the RAM is full, the OS uses some of the secondary storage as Virtual Memory. This means the computer can continue to run. Pages (blocks of data) are transf­erred to the virtual memory when not needed thus freeing up space, and returned to RAM when they are needed.

Operating System

Operating System
Software that provides:
• Process Management
• Memory Management
• Device Management
• User Interface
• File Management

Fundam­entally its software that manage­s/i­nte­rfaces computer hardware and software
The very core of the OS that provides the interface between the user and the hardware. Applic­ations use the kernel to send/r­eceive data from hardware.
Memory Management
A OS must manage the computers memory including adding­/re­moving programs and data from RAM, allowing multiple programs to be run at the same time. The OS also reallo­cates memory when it is no-longer in use (i.e. when a program is closed)

Paging vs Segmen­tation & Virtual Memory
• Segmen­tation. Memory is split into variable sized blocks, and programs are segmented, with each segment being a logical divider. A segment table then maps segments onto memory blocks. Generally slower than paging due to the placement algorithm
• Paging. RAM is split into fixed sized blocks - frames. Programs are split into same-sized blocks - pages. Any page can be placed in any frame, easy to allocate as all equal size.
• If the RAM is full. Pages are transf­erred to the secondary storage acting as memory - Virtual Memory. Pages are moved in/out as needed.
• Thrashing is when pages are being constantly swapped between RAM and V.Mem. It can cause speed issues as the secondary storage's speed << RAM's speed.
Interrupts are a form of error checking. If an error occurs, the interrupt is stored in a priority queue. After the next instru­ction has been executed, the interrupt queue is checked for any interrupt and the processor runs a set of instru­ctions called the Interrupt Service Routine (ISR), with each interrupt having its own ISR. Before the ISR is run, the current values in the registers are stored, so that the processor can return to its previous position. Examples of interrupt types are:
• I/O Interrupt A status of a channel has changed, Occurs when an IO operation is complete or a device is ready.
• Timer Interrupt Allows the processor to preform tasks at intervals
• Program Check Most commonly memory access violations - accessing memory that doesn't exist or is not in use
• Machine Check when hardware
Process Management
Involves the scheduling and switching of programs and threads. Modern PCs have 'multi­tas­king' but it is just clever schedu­ling.
Scheduling Techniques
First Come, First Served
As the name suggests.
• Poor Efficiency

Round Robin
Each process has a set number of processing time. Processor switches in a circular fashion
• Easy Implementation
• Can be inefficient
• Time can be lost waiting for inputs

Shortest Job First
The process with the shortest processing time is processed
• Long Process can be waiting a long time - processor starvation

Shortest time remaining
The process with the shortest remaining processing time is processed. If another job with a shorter time remaining arrives, it will switch
• Short jobs executed quickly
• Starvation can still occur

Multi-­Level Queue
Processes are given a priority when they arrive, dep. on their time remaining, process type and memory size.
• Important jobs processed first

Multi-­Level Feedback Queue
Same as a MLQ but the processor can change the priority of a process, most likely due to a process taking up too much processing time.
• Stops starvation
• Allows interactivity
• Priorities can be changed
Types of OS
• Mostly hidden in devices, generally within the hardware themselves.
• Built into objects
• Have a dedicated purpose
• Little/no user interface
• Fully Autonomous
• Use limited resources - only whats required

• Several progra­ms/­pro­cesses at the same time (concurrent).
• Can either be process management or through parallel processing
• Most General Purpose OS' are now Multitasking

• Must be a multi-­tasking OS too
• Several users accessing the proces­sor­/pr­ogr­ams­/re­sources at the same time.
• Usually a round robin approach.
• Shared processing.

• Inputs being processed under strict time limits. For requirements:
1. Support Non-Se­que­ntial programs
2. Handle parallel and unpred­ictable events
3. Produce responses within the time limit
4. Have fail-safes to guarantee response time

A collection of indepe­ndent nodes, each with its own hardware. The OS presents the systems as an indivi­dual. For example: AI; Weather Foreca­sting; Online Shopping. Each may have the main system on one server, and other things processed on another. The pros of this are that it reduces the load on one computer, and if one fails, it may be able to continue.
Device Management
The OS can make devices acessible to other programs through the use of Device Drivers. It is a piece of software that controls the hardware and provides the interface so that programs and the OS can use the device. Devices cause interrupts on the processor and depending on its priority is when the interrupt is processed.

Waterfall Method

Each of the stages are classified as milestones. Following the method­ology strictly would mean the system is developed flowing down the waterfall. Another version exists where there is iteration back up the steps.

Spiral Method

The method starts in the centre and spirals outwards. The purpose is to elimin­ate­/reduce any project failures by constantly returning to each of the milest­ones. The review stage is where the client is consulted with to determine the progress.


This develo­pment method­ology requires minimal docume­nta­tion, but requires a high amount of involv­ement of the client as a prototype is created, then reviewed then improved upon.

Extreme Progra­mming

This is one on the agile approaches to software develo­pment. It allows for client changes throughout the life cycle and the constant review of progress and client involv­ement give it its name as 'extreme'.

Method­ology Comparison

Progra­mming paradigms

Object Orientated
Code is divided into objects which possess state and behaviour. Follows the principles of encaps­ula­tion, abstra­ction, inheri­tance and polymo­rphism.
The code consists of a series of rules which define a scenario. Answers can be obtained by asking questions in a specific format.
Data Query Languages
Queries to a database or other data structure are specified by what is wanted rather than how to get it.
Code is written to automate processes rather than create entire applic­ations. Scripting languages are often embedded into other systems.
Allows structured progra­mming with sequence, selection, iteration and recursion. Code can be made modular with the use of proced­ures.
Code is divided into isolated functions. There is no global state, only arguments and return values are important. Closely linked to mathem­atics.
Assembly Languages
One to one corres­pon­dence between lines of code and processor instru­ctions. Unlike raw machine code however, you can have variable names and labels.


Compre­ssing a file without the loss of data
Compre­ssing a file by removing redundant data.
Run Length Encoding (RLE)
RLE identifies repeating patterns of data and stores a copy of the inform­ation and how many times it occurs in succes­sion.
Uses a substring search to match strings in the file to be compressed to those stored in a dictio­nary. If a match is found then the string is substi­tuted for the dictionary index. If no match is found, the string is added to the dictionary

Encryption and Hashing

Symmetric Encryption
Encryption that uses the same key to both encrypt and decrypt.
Uses: Encrypted Harddrives
Asymmetric Encryption
Encryption where different keys encrypt and decrypt the data.
Uses: Online transa­ctions
Client­-Server Commun­ication
The client generates a session key and uses the public key to encrypt it

The server decrypts the session key with the private key

Client-Server now commun­icate using symmetric encryption with the session key
Private Key
The private key consists of 2 very large prime numbers
Public Key
The public key is the product of the 2 prime numbers making the private key. As no efficient non-qu­antum integer factor­isation algorithm exists, it is practi­cally impossible to crack the private key by brute force.
Using an algorithm to map data of any size to a fixed size. Unlike encryp­tion, hashing cannot be undone, it is therefore a lossy process.
• Rapid data access in a hash table
• Error checking and corruption detection - such as downloads
• Password verifi­cation - the plain-text password would not have to be stored

A good hash algorithm:*
• Same message = Same hash
• Quick to compute
• Impossible to generate a message from the hash
• A small change = a big hash change
• Impossible to find 2 messages with the same hash


A structured system to hold data
Relational Database
a database structured to recognize relations between stored items of inform­ation.
Flat File Database
A flat file database is a database that stores data in a plain text file. Each line of the text file holds one record, with fields separated by delimi­ters, such as commas or tabs. While it uses a simple structure, a flat file database cannot contain multiple tables like a relational database can.
Any item about which data is stored e.g. Student, Pizza, Stock etc.
A feature of the entity
Foreign Key
A unique identifier to each record held in the relational database.
Composite Primary Key
A combin­ation of 2+ fields that act as a primary key
Foreign Key
A way to build a relati­onship between 2 tables, the foreign key is another tables primary key
Secondary Key
A key that is indexed to allow for faster searching. There can be multiple secondary keys and they don't have to be unique.
Inner Join
Combining columns from one+ tables by using values common to each.

SELECT­lumn1, table2.column2...
FROM table1
ON­mmo­n_field =­mmo­n_f­ield;
Normal Forms
• Each row is unique - it has a primary key
• Each column has a unique name
• No columns with similar or repeated data (i.e. choice1, choice2 etc.)
• Each data item cannot be broken up any further - no commas in the data
• 1NF
• If the primary key is a composite of attributes (contains multiple columns), the non-key attributes (columns) must depend on the whole key.
• 1NF
• 2NF
• There are no non-key attributes that depend on other non-key attributes
INSERT INTO tableName (field­Names) VALUES (values)
SELECT fieldNames FROM tableName WHERE fieldName = value ORDER BY fieldName
UPDATE tableName SET fieldName = value WHERE fieldName = value
DELETE FROM tableName where fieldName = value

DROP tableName
ACID Principles (Trans­act­ions)
Transa­ctions are either done, or not done. Never partially applied
Refere­ntial Integrity and other constr­aints must be adhered to
Transa­ctions preformed simult­ane­ously must have the same result as if they were preformed sequen­tially
Transa­ctions that have been committed must be done fully and remain so.
Concurrent Accessing
Concurrent Access
Is ensuring that more than one user can at least view data at the same time.
Record Locking
Making a file read-only to anybody else who opens the file while changes are being made.
When 2 separate transa­ctions lock the file the other transa­ction needs, thus both are in a state of waiting.
Create a clone of the data item, so the user can make changes, then upload a copy of the clone to the database. This will ensure that no updates or changes can be lost due to uploading a copy of the local version.
Timestamp Ordering
A non-lock way of concurrent access, so multiple people can access the data at one time. The main process is that the lower timestamps occur first.


A definition or a format that has been approved by a recognised standards organi­sation.
de jeur (by force of law) or de facto a standard that has just been accepted over time
An agreed­-upon format for exchanging data between devices. It determ­ines:
• The error checking used
• Compre­ssion method, if any
• How the sender will indicate end of transmission
• How the receiver will indicate the data has been received.
Local Area Network

• Geogra­phi­cally Small (build­ings/a site)
• Equipment is generally owned by the compan­y/p­eople using it
• Generally Faster
• Uses layers 1 and 2 devices - hubs/switches
Wide Area Network

• Geogra­phi­cally remote (across a countr­y/b­etween contin­ent­s/the w.w.w.)
• Connects LANs together with third party teleco­mmu­nic­ation equipment
• Slower speed than LAN
• Uses layer 3 devices - router­s/m­ult­i-layer switches
Network Topologies
Bus Topology
• All devices connected to a central cable (backbone)
• Devices have equal rights
• Collisions can occur if multiple devices send data at once

Star Topology
• A hub at the centre of the network. Requests are sent to all other devices connected to is
• The hub reads the packets and determines the MAC address of the recipient

Ring Topology
• A token is passed around the ring until one of the devices requests to use it.
• The token is filled with the frame of data
• It is passed around the network to each device until it reaches the recipient
• Recipient acknow­ledges the data has arrived.
• One entity (client) requests services from another (server)
• Server stores security inform­ation e.g. logins and permissions.

+ Centra­lised control
+ Single data storage
+ Easy backing up and restoring
+ Remote access
+ Can define security rights and permissions

- Too many requests can cause congestion
- If the server fails, whole network goes down
- Expensive to install and manage
- Requires profes­sionals to install and manage

• All computers have equal rights and act as both a client and server
• Popular applic­ations include the BitTorrent Network, and BitCoin

+ Easy to set up
+ More reliable as central depend­encies are eliminated
+ No-need for a system admini­strator as every user is the admin of their machine
+ Cheaper to implement and maintain.

- Difficult to administor as there is no central dependency
- Less security therefore viruses and other malware can easily be transmitted
- Data recovery is difficult as there is no central storage, each computer requires ots own backup system
- "­(Lots of movies, tv shows and music are transf­erred using P2P, via torren­ts)­"
Packet Switching
A messag­e/data is broken into a number of parts (packets) which are sent indepe­nde­ntly, over whatever route is optimum for each packet, and reasse­mbled at the destination.

+ Efficient use of a network
+ Can easily circumvent broken sections of a network
+ Network only has to increase slowly as demand does

- Time taken to rebuild packets is variable - an issue for time-s­ens­itive data
- Not good for small data.
Circuit Switching
Commun­ication where a dedicated channel (or circuit) is establ­ished for the duration of a transmission.

+ Data arrives in order sent
+ No additional inform­ation has to be added - e.g. headers

- Portion of the network is unavai­lable while in use
- Data is easily interc­epted.
Domain Name System (DNS)
A system that converts the web address: www.we­bsi­te.s­om­ething into the IP address of the host server.
MAC Address
Unique 6-byte identifier that is given to NICs. Assigned to the NIC by the manufa­cturer.
Most commonly used IP version. Its a 32-bit system, so there are 232 addresses available.
IPv6 is a 128-bit address, so there are 2128 addresses available.
TCP/IP Stack
Applic­ation Layer
The Applic­ation layer ensures the data is sent in an unders­tan­dable format by the recipient. It formats the data to meet the standards of the protocol.
Transport Layer
The transport layer takes the data and splits it into data packets. Each one is given a number, specifying the order so it can be recons­tru­cted. The port number is also added depending on the applic­ation being used for example HTTP is port 80.
Network Layer
The network layer is where the IP of the sender is attached, so the recipient can send a message saying the packets were received. It also attaches the recipients IP. This is also the layer where the Time To Live (TTL) is added to the header. It governs how many times the packet can hop before deleting itself, this ensure infinite loops don't occur.
Link Layer
This is the layer where the MAC address of both the sender and recipient is attached, allowing the packets to be directed to a specific NIC.
Intern­et/­Network Protocols
HTTP (Hypertext Transfer Protocol)
Defines how webpages are transf­erred from server to the client. The HTTP will make a request to the IP and the server responds with a webpage. There are 8 different HTTP commands including GET, POST and CONNECT*
HTTPS (Secure Hypertext Transfer Protocol)
Connects via a different port and encrypts the data between the HTTP and the TCP protocols.
FTP (File Transfer Protocol)
The protocol used to download and upload files. Most modern browsers have built in FTP
POP3 (Post Office Protocol 3)
Allows emails to be received from a server. The protocol connects to the email server, downloads a local copy then deletes them from the server.
SMTP (Simple Mail Transfer Protocol)
Used for sending emails
SSH (Secure Shell)
Remote­-access protocol, allows secure commun­ication between a client and server
CSMA/CA (Carrier Sense Multiple Access with Collision Avoidance)
Is a transm­ission protocol that prevents packet collis­ions. Once it receives a packet, it checks whether the channel is clear, if it is not available it will generate a random wait time, when it will check again.

If a packet is larger than the permitted size is needed to be sent, a handshake needs to occur first - the RTS/CTS (Request to Send/Clear to Send) protocol. This protocol only occurs when the packet is larger than the threshold.
Network Security
A embedded program intended to cause damage to a PC. It copies itself onto the disk and hides itself. It attempts to duplicate itself and spread to other computers.
A virus but it is contained within its own program.
A non-se­lf-­rep­lic­ating virus hidden in a downloaded file, and unleashed on execution.
Ransom Ware
A trojan­/worm that encrypts data and then charges the owner to decrypt it.
The purpose of a firewall is to control the traffic flowing in and out of a network. It can be hardware or software based, and sometimes is a combin­ation of both. It can be setup to block individual website addresses or specific computers.
Proxy Server
f a user requests a service from the network, it is first passed to the proxy, before the proxy server then performs the request on the behalf of the network user. If the resource is banned the request can be rejected, There is never any direct contact between user and resource, as the proxy acts as a "­middle man".
It requires you to enter a password when accessing a network. It acts as layer of protec­tion.
Network Hardware
It receives a signal from a node and transmits it to all the other nodes. It is cheap and effective for small networks but for larger networks causes too many collisions
A switch has a small amount of internal memory, that allows it to generate a look-up table. When data is sent the switch finds the approp­riate node. Unlike a hub, it doesn't send the data to all the nodes, just the receiver.
A device that forwards packets from one network to another.
The entrance and exit of networks. The main use is to connect multiple networks with different archit­ectures

Search Engines

Overall Search engine
Crawling the web with 'spiders' TF-IDF (Term Frequency - Inverse Document Frequency) The PageRank algorithm Other factors, such as domain name, page age, mobile friend­liness
Page Rank
PageRank works by counting the number and quality of links to a page to determine a rough estimate of how important the website is. The underlying assumption is that more important websites are likely to receive more links from other websites.

Data Types

A whole number
Float is a term is used in various progra­mming languages to define a variable with a fractional value. Numbers created using a float variable declar­ation will have digits on both sides of a decimal point. This is in contrast to the integer data type, which houses an integer or whole number.
A value with a True or False condition - can possibly use 0/1 instead
A single keyboa­rd/­unicode character
A set of charac­ters, used to store text.
A repres­ent­ation of time. Can be repres­ented in either text or number format
Number Bases
Binary (Base 2)
Groups of bits in 1 and 0 (2 possible values). It uses positional numbering but with powers of 2, not 10 (denary numbers - normal)
Hexade­cimal (Base 16)
Denary (Base 10)
Normal number formats with the positional numbering in powers of 10.
Sign & Magnitude
A form of showing negative binary numbers where the first bit is the sign (0 = +ve, 1= -ve). Immedi­ately you have reduced the range of values as one of the bits is reserved for the sign.
Two's Comp
A improved way of showing negative numbers. If the first bit is a 1, it is taken as the negative version, and all following numbers are added to it. If it is a zero, it behaves just like a negative number.

To change a normal +ve binary number to twos comp. Flip the bits, and add 1
01101010 = 106
10010101 (Flip the bits)
10010110 = +1
10010110 = -106
Fixed Point Binary
A method of showing floats. The decimal is fixed so there is a set amount of integer bits and a set number of fractional bits. The fractional parts follow the same positional numbering (powers of 2) but the negative versions i.e. 2-1, 2-2, etc.
Floating Point Binary
A method of showing binary composed of 2 parts: the mantissa, and the exponent. The mantissa is the actual number, and the exponent is the number of units to move the floating point up or down by.

10101011 | 0011
Mantissa | Exponent

1.0101011 x 2 0011
1.0101011 x 23

1010.1011 = 10.6875

The rule for powers:

(Decrease the power, per jump right)
When very small numbers, and the boundary of what the computer can store is reached. For example, 128-1 x 128 -1 requires 14 bits to be stored.
A calcul­ation that results in a number too large to be stored. For example, any numbers past x10100 on most calcul­ators

Logic Gates

Half Adder
Add two single bits, produces an output S, and a carry signal C. It consists of an AND gate (C) and a XOR gate (S) in parallel.
Full Adder
Full adders are a combin­ation of 2+ half adders. Where the C of both half adders, connects to a OR gate (C
) and the sum of one connects as the input of another.
Basically treating the first HA as another input.
Basic Flip-Flop
Takes a set and a reset signal. The idea is that the FF stays in one state until the change signal is sent.
D (Data) Type Flip Flop
Stores the signal it receives if it is enabled. It takes in an extra input D.


No comments yet. Add yours below!

Add a Comment

Your Comment

Please enter your name.

    Please enter your email address

      Please enter your Comment.

          Related Cheat Sheets

          Pseudocode Cheat Sheet

          More Cheat Sheets by 0llieC

          A-Level Physics Key Terms Cheat Sheet