Table of contents
Let's continue in our quest to dig up the internals of a blockchain. In this post, we shall explore one of the fundamentals that incentivizes people to actually support a blockchain. Let's start by gathering up what a block looks like till now.
Is it really that simple?
On the basis of the information we currently know, we may think that it is pretty easy to generate the hash of a block. And it will be a fair assumption because it will take some milliseconds at most to generate a hash for some given data. But then, what is all the fuss about mining and it taking so much resources. As it turns out, there is another field in a block and its finally time to reveal it.
The Other Field
This next field is called the nonce. Let's start how we always do, and that is with a good old definition:
A nonce is an abbreviation for "number only used once," which, in the context of cryptocurrency mining, is a number added to a hashed—or encrypted—block in a blockchain that, when rehashed, meets the difficulty level restrictions.
Why tho?
It seems counter intuitive to add a random value to the block, when it seems like it doesn't serve any meaningful purpose. The nonce is just a random value that is used to influence the hash of the block due to the Avalanche Effect. Still not sure? Let's see 2 pictures to illustrate it better. Notice the nonce and the hash. Saw the change? Good. Hopefully now we are on the same page.
Conclusion
This was a very short post. This is because we are only setting the stones in place for the post on The Cryptographic Puzzle.
Thank you and see you in the next one!