So that means finding a hash value with certain properties
is expected to require an amount of work,
and by adjusting those properties we can increase the amount of work.
So this is what Bitcoin does.
In order to create a new block,
which would validate the next history of transactions,
it's necessary to find some value X such that
the hash of the hash of the state
concatenated with X is less than some target.
You keep increasing the value of X
until you find one that satisifies that property,
and that provides the timestamp
that allows a new block to be generated.
So this is the idea Bitcoin uses to generate a timestamp.
You have to keep finding new blocks,
and a block will validate a set of transactions.
But to generate a new block, you've got to find a new timestamp,
which is this target.
So you've got to find a value
where the hash of the hash of the state concatenated with that value--
and the state does two important things.
It includes information about the previous block--
this is how the timestamps form a chain.
The state must include the previous block.
It also includes some information that's likely to be unique
for each member of the network.
This is how they avoid it being the case that they're all racing to find the same value X.
So given those properties,
then the goal is to find the value X that you can concatenate with that
to be less than some target.
And the value of the target controls how hard it is to find.
And the way the Bitcoin currency is designed to work
is this value of the target is adjusted in a way
that makes the time to find X keep about 10 minutes.
That's the time for the whole network to find the next value
so that that value of the target
will keep decreasing as the computing power in the network increases.
And if you go to the Bitcoin website, you can see the current value of the target,
which is this value that--
In order to create a new block, you've gotta find an X value
such that this property is less than the target.
And I should emphasize that these 0s are not just 1 bit.
This is hex.
So each one of these 0s is 4 bits.
So if you've got to find a value
where the hash starts with 54 zeros
followed by something less than 101 and more--
so if you found a value that hashed
where the result started with 55 zeros
or started with 54 zeros, a 1-0, and 0,
well then you'd be golden.
You'd be able to create the next block.
That would allow you to earn the value
of a new block, which currently is 50 Bitcoins.
Each Bitcoin is worth about $5.
So finding a hash that hashes to this would be worth about $250.
And the rest of the network can verify that.
It can compute this same hash function,
verify that for the X value that you found
the value is less than target,
and that will add that block to the Bitcoin network.
So the difficultly of finding such hashes keeps decreasing.
The reason it's so low is because of using GPUs.
If you were using a regular processor,
it would use far more than $250 in computing power
to find such a hash value.
If you have a GPU, there are algorithms
for implementing the hash function more efficiently.
That would mean that finding a value that satisfies this property
should require about that much value in computing power.
So to see if this makes sense,
I want to ask why the timestamp function--
the one here to find the next block--
uses two hashes instead of one. Here are the choices.
See if you can figure out which one would make the most sense
as to why there are two hash functions here.
