HelpContactFor teachers and institutes
>_StemPy Lab
Mock TestsClasses

>_StemPy Lab

Learn. Solve. Code the solutions. Test yourself.

Live examsFree mock exams, timed and rankedEveryone starts together, and your score and rank come the moment it ends.See the exams →

Learn

  • Physics
  • Chemistry
  • Mathematics
  • Biology
  • Python Programming
  • Statistics & Data Science
  • Computer Science
  • Classes
  • Groups

Practice

  • Problems
  • Quizzes
  • Mock Tests
  • Prepare for an Exam
  • Question Sets
  • Exams
  • Certificates
  • Python Labs
  • AI Practice Generator
  • Student-Created Tests

Community

  • Discussions
  • Resources
  • Notes
  • Glossary
  • Blog

Account

  • Log in
© 2026 senLearn. All rights reserved.HelpFor SchoolsAboutContactPrivacy PolicyTerms of UseRefund Policy
  1. Problems
  2. /A blockchain has 9 blocks. A person changes the amount of a payment in block 4…
MediumComputer ScienceHigh School (9–10)Computer Science › The Internet, the Web and Digital CurrencyNumericalIGCSE

A blockchain has 9 blocks. A person changes the amount of a payment in block 4…

StemPy LabContributed by StemPy Lab

Try it on paper first. A hint, the key idea and the worked solution are here when you need them.

A blockchain has 999 blocks. A person changes the amount of a payment in block 444.

  1. Between which two blocks does the chain first stop fitting together?
  1. To hide the change, how many blocks must get a new hash? Count block 444 itself.
  1. How many blocks are not affected at all?

Check your answer

Work it out on paper, then type your number. The answer itself stays hidden.

Need a reminder? The key ideaShowHide

A blockchain is a digital ledger: a time-stamped series of records that cannot be altered. Each block holds its data, a time-stamp, the hash of the previous block and its own hash. A tiny change in the data gives a completely different hash. If block kkk of nnn is changed, every block from kkk to nnn needs a new hash:

r=n−k+1.\displaystyle r = n - k + 1.r=n−k+1.

The worked solution

Have you tried it?

Work it out on paper first. It is fine to get stuck or make a mistake: that is how we learn. When you are ready, go through the solution one step at a time, and check each step against your own.

Step 1. Where it breaks. Changing the data changes block 444's hash. Block 555 still stores the old hash of block 444, so the chain stops fitting between blocks 444 and 555.

Step 2. Blocks to change. Blocks 4,5,6,7,84, 5, 6, 7, 84,5,6,7,8 and 999: r=9−4+1=6r = 9 - 4 + 1 = 6r=9−4+1=6 blocks.

Step 3. Untouched blocks. Blocks 111, 222 and 333 come before the change: 333 blocks.

Check. 6+3=96 + 3 = 96+3=9, the whole chain.

Answer: (a) between blocks 444 and 555. (b) 666 blocks. (c) 333 blocks.

Log in to save this for later
← All Problems
← A blockchain records payments of a digital currency…A student designs a "blockchain" in which each block holds only its data, a time-stamp and its own… →
More onComputer Science › The Internet, the Web and Digital Currency

Discussion (0)

Log in to join the discussion.

Loading…

More on this topic

  1. Part of a blockchain holds these payments, oldest first…Hard
  2. A blockchain has 56 blocks. A new block is added to the honest chain every 10 minutes…Hard
  3. Kemal pays Dana 9 units of a digital currency that uses a blockchain…Medium
  4. A blockchain is copied on 40 computers in a network…Medium
  5. A student designs a "blockchain" in which each block holds only its data, a time-stamp and its own…Hard
All problems on this topic →