Syllabus coverage
- Understand the concept of a digital currency: a currency that only exists electronically, with balances held as data rather than as coins or notes
- Understand how digital currencies are used, including holding a balance in a digital wallet and transferring value from one address to another as a recorded transaction
- Understand the process of blockchain: transactions are grouped into time-stamped blocks, and each block is linked to the block before it so that records cannot be altered
- Understand how blockchain is used to track digital currency transactions, so that the same unit cannot be spent twice and no single party can rewrite the history of payments
Part of the O Level Computer Science syllabus 2210.
A currency that exists only as data
A digital currency is one that only exists electronically. There are no coins in a pocket and no notes in a till: the balance is held as data in a computer system, and paying somebody means changing that data so that the amount moves from one holder to another. Nothing physical is handed over, and there is no drawer of cash anywhere behind the payment.
This is not the same as internet banking. When you pay a shop from a normal bank account, the money in that account is also just a number in a database, but the currency itself still exists as notes and coins and the bank is obliged to convert your balance into them. A digital currency has no physical version at all: there is nothing to withdraw, and the only form it takes is the record of who holds how much.
Because there is nothing to hold, ownership is proved entirely by the record. Whoever the ledger says holds a unit is the person who can spend it. That makes the record itself the thing of value, and it explains why so much of this topic is about how the record is kept rather than about the money.
How a digital currency is used
A user holds a digital currency in a digital wallet, which is software or a device that stores the private key needed to authorise spending. The wallet does not contain the currency any more than a card contains a bank balance: it holds the key that proves the right to move a balance that is recorded in the ledger.
Each holder has a public address, a string of characters that others can send funds to, rather like an account number that is safe to share. The matching private key is what signs a payment out. To pay somebody, the payer's wallet creates a transaction naming the payer's address, the recipient's address and the amount, and signs it with the private key. That transaction is broadcast to the network of computers that maintain the ledger.
The network checks the transaction before it is accepted. It confirms that the signature is valid and that the payer's address actually holds enough to cover the amount and has not already committed those funds elsewhere. Once enough of the network agrees, the transaction is added to the ledger and the balances at both addresses change. The recipient can see the payment arrive without needing to trust the payer, because the check was done against the shared record rather than against the payer's word.
There is no bank in the middle of that process. No single institution holds the balance, approves the payment or can reverse it, which is the feature that attracts some users and the drawback that worries others: a payment sent to the wrong address, or made under pressure, cannot be called back by a customer service desk.
- A wallet stores the private key; the balance itself lives in the ledger.
- A public address can be shared so that others can send funds to it.
- A payment is a signed transaction naming payer, recipient and amount, broadcast to the network.
- The network validates the signature and the available balance before the transaction is recorded.
- No central bank or institution sits in the middle, so recorded payments are not reversible.
The problem a shared record has to solve
Digital data can be copied perfectly and instantly. If a digital currency were just a file, a holder could send the same file to two different people, and both would believe they had been paid. This is the double-spending problem, and any digital currency has to prevent it.
A central authority could prevent it simply by keeping the only copy of the balances and approving each payment in turn, which is roughly what a bank does. A digital currency built to work without a central authority cannot rely on that, so it needs a record that many independent computers hold, check and agree on, and that no single one of them can rewrite.
That shared record also has to settle disputes about order. If two payments from the same address are broadcast at nearly the same moment, the network must agree which one came first, because only the first can be paid from the available balance. A record built as a chain of blocks solves both problems at once: it gives one agreed history, and it makes any attempt to change an earlier entry visible to everybody.
The blockchain: a ledger that cannot be altered
A blockchain is, in its basic form, a digital ledger: a time-stamped series of records that cannot be altered. A ledger is simply a record of transactions, and here that record is kept as data, shared across a network of computers rather than in one organisation's database.
The record is built out of blocks. A block is a container holding a batch of transactions together with information about itself: the time it was created, and a value called a hash that is calculated from its contents. Blocks are added one after another in a fixed order, and each new block also stores the hash of the block before it. That stored reference is what turns a pile of blocks into a chain.
A hash is a fixed-length value produced by a mathematical function from the block's contents. The same contents always produce the same hash, and any change to the contents, even a single character, produces a completely different one. It is a one-way function: you cannot work backwards from the hash to the contents. That is what makes it useful as a fingerprint for a block.
The ledger is not kept in one place. Many computers on the network hold their own copy, and new blocks are accepted only when the network agrees they are valid. The result is a record of transactions that every participant can check and that no single participant controls.
- A blockchain is a digital ledger: a time-stamped series of records that cannot be altered.
- Transactions are collected into blocks, and blocks are added in a fixed order.
- Each block stores its own timestamp, its list of transactions and the hash of the previous block.
- Many computers hold a copy of the ledger, so there is no single copy to tamper with.
How the chain is built, block by block
New transactions arrive at the network and wait in a pool, unconfirmed. Computers on the network check each one: is the signature valid, does the address hold enough, has this unit already been spent in an earlier block? Transactions that pass are gathered into the next block, and the block is stamped with the time it was assembled.
The block is then sealed. Its transactions are put through the hash function together with the timestamp and, crucially, the hash of the previous block, and the result becomes this block's own hash. That hash is written into the block header and also copied into the next block when it is built, which is the link in the chain.
Adding a block is deliberately made difficult, so that blocks cannot be produced faster than the network can agree on them. In many systems the computers compete to find a value that makes the block's hash meet a required pattern, and the winner broadcasts the finished block for the others to check. The other computers verify the work and the contents, and if it all holds they add the block to their own copy. This is commonly called mining, and the reward for it is the incentive that keeps computers participating.
The exact rules differ between one digital currency and another, but the structure does not: transactions are batched, the batch is time-stamped, the batch is hashed together with the hash of its predecessor, and the network agrees to append it.
| Part of a block | What it holds | Why it matters |
|---|---|---|
| Timestamp | When the block was created | Puts the transactions in time order, so the ledger is a dated series of records |
| Transaction list | The transfers accepted into this block | The actual record of who paid whom, and how much |
| Hash of the previous block | The fingerprint of the block before it | Links each block to its predecessor, forming the chain |
| Own hash | The fingerprint calculated from this block's contents | Any later change to the block changes this value, which breaks the link to the next block |
Why tampering shows, and how transactions are tracked
Suppose somebody edits a transaction in an old block to send themselves more. The contents of that block change, so the hash calculated from them no longer matches the hash that was recorded for it. The next block still stores the original hash of its predecessor, so the two no longer agree and the chain is visibly broken at that point.
To hide the edit, the attacker would have to recalculate that block's hash and then every hash after it, because each block's stored reference would also have to be rewritten. On top of that, most other computers hold their own copies of the ledger and check new blocks against the rules; a rewritten chain that disagrees with the majority is rejected. Altering history therefore stops being a matter of changing one record and becomes a matter of out-computing most of the network, which is what makes the record effectively unalterable.
This is how a blockchain tracks digital currency transactions. Every transfer is written into the ledger, in a dated block, in a position in the chain that everyone can see. A holder wanting to prove they have funds shows the transactions that paid them, and anyone can check that those transactions exist in the chain and have not been spent again. Because the chain records the movement of each unit from address to address, the same unit cannot be spent twice: the first valid spend is in the chain, and a second attempt fails validation.
The ledger is also pseudonymous rather than anonymous in the ordinary sense. Addresses are not names, but every transaction involving an address is permanently visible to everyone holding the ledger. If an address is ever linked to a person, the whole history attached to it becomes linkable too. That openness is a feature for auditing and a concern for privacy, and both follow from the same design decision to make the record shared and unalterable.
- Changing an old block changes its hash, so the next block's stored reference no longer matches and the break is visible.
- Hiding the change would mean recalculating every later block and beating the rest of the network's copies.
- Each transaction sits in a dated block at a fixed position, so a unit's history can be traced from address to address.
- Once a valid spend is recorded, a second attempt to spend the same unit fails validation.
- Addresses are pseudonymous, but all activity against an address is permanently visible.
What the design gives, and what it costs
The strengths follow directly from the structure. There is no single point of failure or single organisation that must be trusted, because many computers hold and check the ledger. Records are time-stamped and effectively permanent, which suits auditing. Transactions can be verified by anyone with a copy, and cross-border transfers do not wait for banks in two countries to settle between themselves.
The costs also follow from the structure. Because every participant keeps a copy and every block must be agreed, the network does more work than a single database would: the same transaction is stored many times, and the agreement process consumes computing power and electricity. Throughput is limited by how quickly blocks can be agreed, so a blockchain can be much slower than a central database for the same volume of payments.
There is also the question of responsibility. A mistaken payment cannot be reversed, a lost private key means the balance can never be moved again by anyone, and the value of a digital currency against ordinary money can change sharply because nothing fixes it. Those are not faults in the blockchain itself; they are consequences of running a currency without a central authority that could undo, restore or stabilise.
| Advantage | Disadvantage |
|---|---|
| No single organisation controls the ledger, so there is no central point of failure or trust | Agreement across many computers is slower and uses far more computing power than one database |
| Records are time-stamped and effectively cannot be altered, which makes them auditable | A payment recorded in error cannot be reversed |
| Anyone holding a copy can verify transactions independently | A lost private key means the funds can never be spent |
| Transfers can cross borders without waiting for banks to settle | The exchange rate against ordinary currency can change sharply |
Key terms you must be able to define
- Digital currency
- A currency that only exists electronically: the balance is held as data and payments move that data, with no coins or notes in circulation.
- Blockchain
- In its basic form, a digital ledger: a time-stamped series of records that cannot be altered, built from blocks linked to the block before them.
- Digital ledger
- A record of transactions kept as data. A blockchain is one, shared across many computers rather than held by a single organisation.
- Block
- A container in the chain holding a batch of transactions, a timestamp, the hash of the previous block and its own hash.
- Hash
- A fixed-length value calculated from a block's contents. The same contents always give the same hash, and any change gives a completely different one, so it acts as a fingerprint.
- Transaction
- A record of a transfer naming the payer's address, the recipient's address and the amount, signed with the payer's private key.
- Digital wallet
- Software or a device that stores the private key needed to authorise payments of a digital currency; the balance itself is held in the ledger.
- Private key
- The secret value that proves the right to spend from an address and is used to sign transactions. Anyone who has it controls the funds.
- Public address
- A string of characters, safe to share, that others use to send funds; the matching private key is needed to spend what arrives.
- Double spending
- Sending the same digital unit to two different recipients. A blockchain prevents it by recording the first valid spend permanently.
- Timestamp
- The record of when a block was created, which places its transactions in order within the ledger.
- Mining
- The process by which computers on the network compete to assemble and seal the next block, and are rewarded for doing so.
- Validation
- The checks the network performs on a transaction or block: that the signature is valid, the balance is sufficient and the unit has not already been spent.
In context
2210 sets its questions inside systems a student already uses - a school network, a phone, a supermarket till, a vending machine, a website. These show how the theory is applied to a context you have not seen before, then you answer for the system you are given.
The payer opens a wallet, enters the friend's public address and the amount, and confirms. The wallet signs the transaction with the private key and broadcasts it. Computers on the network check the signature and the balance, the transaction is included in the next block, and once that block is agreed the friend's address shows the funds. No bank approved it and nobody can reverse it, so typing the address correctly matters more than it does in ordinary banking.
The shop displays a public address as a QR code. The customer's wallet builds a transaction to that address and signs it. The shop waits for the transaction to appear in a block before handing over the goods, because an unconfirmed transaction is only a request, and the whole point of the ledger is that confirmation is what makes the payment final. The shop then converts the balance into ordinary currency if it does not want to hold the risk of the exchange rate moving.
A charity publishes its public address. Any donor can follow every transfer out of it in the ledger, because each one sits in a dated block that anybody can read. Nobody needs the charity's permission to check, and nobody, including the charity, can quietly remove a payment that has already been recorded. The donors still have to work out which addresses belong to the charity, since the ledger gives addresses rather than names.
Someone with access to an old copy of the ledger edits a transaction from a year ago. The block's hash changes, so the hash stored in the following block no longer matches, and the break is visible at that point. Rebuilding the chain from there would mean recalculating every later block and producing a version longer than the one the rest of the network holds, which is not feasible. The other copies simply reject it.
A user's phone held the only copy of a private key. There is no customer service line to call and no password reset, because no organisation holds the account: the ledger still records the balance against the address, but nobody can sign a transaction to move it. The loss is permanent, which is the other side of having no central authority able to restore access.
Flashcards
Click a card to flip it. Mark honestly — the tracker uses this.
Exam-style questions
6 questions, 20 marks. Write your answer and press Mark my answer — it is marked against the scheme and tells you which points you made and what would gain the next mark. You can still reveal the scheme and mark it yourself instead.
Mark scheme — tick each point you actually made
Mark scheme — tick each point you actually made
Mark scheme — tick each point you actually made
Mark scheme — tick each point you actually made
Mark scheme — tick each point you actually made
Mark scheme — tick each point you actually made
Exam technique for this topic
- Define a digital currency in the syllabus words: one that only exists electronically. If you add 'like online banking', make clear that ordinary money still has a physical form, or leave the comparison out.
- Keep the currency and the ledger apart. The blockchain is not money; it is the record that tracks the money. Answers that begin 'blockchain is a type of digital currency' lose the definition mark immediately.
- For the process question, write the chain in order: transactions are collected, a block is formed and time-stamped, the block is hashed together with the previous block's hash, the network validates it, and it is appended. Five stages, five marks.
- For 'why can the ledger not be altered', give the mechanism rather than the adjective. Say that a changed block no longer matches its recorded hash, and that every later block would have to be recalculated and accepted by the majority of copies.
- Do not invent figures about prices, energy use or transaction speeds. Describe the trade-off in words: agreement across many computers is slower and more demanding than one central database.
Why students lose marks here
Where this fits in O Level Computer Science 2210
This page is one topic of Cambridge O Level Computer Science 2210. O Level Computer Science 2210 is the course home: every area and every topic in Cambridge's own order, the papers you sit and what each one tests, and the exam-practice tools. The full topic list, with each topic linked to its revision page, is on the O Level Computer Science 2210 syllabus page.