Bird
Raised Fist0
Blockchain / Solidityprogramming~10 mins

Why blockchain exists - Visual Breakdown

Choose your learning style10 modes available
Concept Flow - Why blockchain exists
Need for trust in transactions
↓
Central authority controls data?
No→Risk of fraud, hacking
Yes↓
Single point of failure
↓
Idea: Decentralize data
↓
Use blockchain: shared ledger
↓
Immutable, transparent records
↓
Trust without middleman
↓
Goal achieved
This flow shows why blockchain was created: to build trust without a central middleman by using a shared, unchangeable ledger.
Execution Sample
Blockchain / Solidity
transactions = []
for tx in new_transactions:
    if verify(tx):
        transactions.append(tx)
    else:
        reject(tx)
This code simulates adding only verified transactions to a shared list, like blockchain only accepting valid data.
Execution Table
StepTransactionVerification ResultActionLedger State
1tx1TrueAdd to ledger[tx1]
2tx2TrueAdd to ledger[tx1, tx2]
3tx3FalseReject transaction[tx1, tx2]
4tx4TrueAdd to ledger[tx1, tx2, tx4]
Exit--No more transactions[tx1, tx2, tx4]
💡 All new transactions processed; only verified ones added to ledger
Variable Tracker
VariableStartAfter 1After 2After 3After 4Final
transactions[][tx1][tx1, tx2][tx1, tx2][tx1, tx2, tx4][tx1, tx2, tx4]
Key Moments - 3 Insights
Why do we reject some transactions?
Transactions that fail verification are rejected to keep the ledger trustworthy, as shown in step 3 of the execution_table.
Why can't one person control the ledger?
If one person controlled it, they could change records unfairly. Blockchain shares the ledger to avoid this single point of failure, as explained in the concept_flow.
What does 'immutable' mean in blockchain?
Immutable means once a transaction is added, it cannot be changed or deleted, ensuring trust. This is why only verified transactions are appended, never removed.
Visual Quiz - 3 Questions
Test your understanding
Look at the execution_table, what is the ledger state after step 2?
A[tx1, tx2, tx3]
B[tx1]
C[tx1, tx2]
D[]
💡 Hint
Check the 'Ledger State' column at step 2 in the execution_table.
At which step is a transaction rejected?
AStep 3
BStep 1
CStep 4
DNo rejection
💡 Hint
Look for 'Reject transaction' in the 'Action' column of the execution_table.
If all transactions passed verification, what would happen to the ledger?
AIt would contain only the first transaction
BIt would include all transactions
CIt would be empty
DIt would reject all transactions
💡 Hint
Refer to the 'Verification Result' and 'Action' columns in the execution_table.
Concept Snapshot
Why blockchain exists:
- To build trust without a central middleman
- Uses a shared, unchangeable ledger
- Only verified transactions are added
- Prevents fraud and single points of failure
- Enables transparent and secure record keeping
Full Transcript
Blockchain exists because people need a way to trust transactions without relying on a central authority. Central control can lead to fraud or failure. Blockchain solves this by sharing a ledger that everyone can see and verify. Only valid transactions get added, and once added, they cannot be changed. This creates trust through transparency and security without a middleman.

Practice

(1/5)
1. Why was blockchain technology created?
easy
A. To make computers run faster
B. To allow people to trust data without needing a middleman
C. To store large video files efficiently
D. To replace all traditional databases

Solution

  1. Step 1: Understand the main purpose of blockchain

    Blockchain was designed to create trust in data without relying on a central authority or middleman.
  2. Step 2: Compare options with blockchain's purpose

    Options B, C, and D do not match blockchain's core goal of trust and decentralization.
  3. Final Answer:

    To allow people to trust data without needing a middleman -> Option B
  4. Quick Check:

    Blockchain = Trust without middleman [OK]
Hint: Blockchain = trust data without middleman [OK]
Common Mistakes:
  • Thinking blockchain is just a faster database
  • Confusing blockchain with file storage
  • Believing blockchain replaces all databases
2. Which of the following is the correct way to describe a blockchain?
easy
A. A chain of blocks where each block links to the previous one
B. A single large block storing all data
C. A random collection of unrelated data blocks
D. A block that changes data easily

Solution

  1. Step 1: Recall blockchain structure

    Blockchain is made of blocks linked in order, each pointing to the previous block.
  2. Step 2: Eliminate incorrect descriptions

    Options A, B, and D do not describe the linked and secure nature of blockchain blocks.
  3. Final Answer:

    A chain of blocks where each block links to the previous one -> Option A
  4. Quick Check:

    Blockchain = linked blocks [OK]
Hint: Blockchain links blocks in order securely [OK]
Common Mistakes:
  • Thinking blockchain is one big block
  • Believing blocks are unrelated
  • Assuming blocks can be changed easily
3. Consider this simple blockchain data structure in Python-like pseudocode:
blocks = [
  {'index': 1, 'data': 'A', 'prev_hash': '0'},
  {'index': 2, 'data': 'B', 'prev_hash': 'hash1'},
  {'index': 3, 'data': 'C', 'prev_hash': 'hash2'}
]
print(blocks[1]['data'])
What will be the output?
medium
A. A
B. hash1
C. C
D. B

Solution

  1. Step 1: Identify the list index accessed

    blocks[1] accesses the second item in the list, which has data 'B'.
  2. Step 2: Access the 'data' key of that block

    blocks[1]['data'] returns 'B'.
  3. Final Answer:

    B -> Option D
  4. Quick Check:

    blocks[1]['data'] = B [OK]
Hint: List index 1 is second item, data is 'B' [OK]
Common Mistakes:
  • Confusing list index starting at 0
  • Mixing data and prev_hash values
  • Assuming index key affects list indexing
4. This code tries to add a new block to a blockchain list but has an error:
blockchain = [{'index': 1, 'data': 'A', 'prev_hash': '0'}]
new_block = {'index': 2, 'data': 'B', 'prev_hash': blockchain['index']}
blockchain.append(new_block)
print(blockchain)

What is the error?
medium
A. Cannot use blockchain['index'] because blockchain is a list, not a dict
B. Missing 'data' key in new_block
C. append() method does not exist for lists
D. Index value should be a string, not a number

Solution

  1. Step 1: Identify the type of 'blockchain'

    blockchain is a list, so blockchain['index'] is invalid syntax.
  2. Step 2: Understand correct way to get last block's index

    To get last block's index, use blockchain[-1]['index'], not blockchain['index'].
  3. Final Answer:

    Cannot use blockchain['index'] because blockchain is a list, not a dict -> Option A
  4. Quick Check:

    List indexing needs integer, not string key [OK]
Hint: List uses numeric indexes, not string keys [OK]
Common Mistakes:
  • Using string keys on a list
  • Forgetting to access last element with -1
  • Confusing append() with other methods
5. You want to create a simple blockchain that stores ownership records. Which feature of blockchain helps ensure records cannot be changed without everyone noticing?
hard
A. Blocks can be edited by anyone at any time
B. Blocks are stored in a single central database
C. Blocks are linked by hashes that depend on previous blocks
D. Blocks are deleted after 24 hours automatically

Solution

  1. Step 1: Understand blockchain's security feature

    Each block contains a hash that depends on the previous block's data, linking them securely.
  2. Step 2: Explain why this prevents unnoticed changes

    If any block changes, its hash changes, breaking the chain and alerting everyone.
  3. Final Answer:

    Blocks are linked by hashes that depend on previous blocks -> Option C
  4. Quick Check:

    Hash linking = tamper detection [OK]
Hint: Hash links blocks to detect changes [OK]
Common Mistakes:
  • Thinking blockchain is centralized
  • Believing blocks can be freely edited
  • Assuming blocks are temporary
Recommended

Ready to prove it?

Pass the test and this pattern moves unknown strong while earning +1 Grip toward your certificate.

10 questions~5 mineasy hard