Sentence Chain
Teaches: Blockchain | 7 min | You need: Nothing!
What you will learn
A blockchain links records together so changing one breaks all the ones after it.
Steps
- 1
Think of a sentence. Count the letters. That number is your "hash". Example: "I like cats" = 10 letters. Hash = 10.
- 2
Think of a second sentence. Start it with the hash of the first: "10 dogs run fast" = 14 letters. Hash = 14.
- 3
Third sentence starts with 14: "14 birds flew south" = 17 letters. Hash = 17.
- 4
Now go back and CHANGE the first sentence to "I like dogs" = 10... wait, same hash? Try "I like big cats" = 14. New hash = 14!
- 5
But the second sentence starts with "10", not "14". The link is BROKEN!
- 6
To fix it, you would need to redo sentence 2 AND sentence 3. That is why blockchains are so hard to cheat.
What you learned
Each block links to the one before it. Change any block and all the links after it break. This makes the record tamper-proof.
Play with others?
Each person writes a sentence and passes the hash to the next person. Then try to change an early sentence. Everyone sees the chain break!