<p>What you are asking is: can I create valid blocks (with only a coinbase transaction to and address of my choice) with a previous block hash that I chose at random that will be made valid if another block occurs with that hash.</p>

<p>Sure you can. Note that there are 2^256 hashes. The chance of finding one at random that will equal the hash of a to-be-discovered block are very very small. You would most probably just be wasting computing power/electricity/time. </p>

<p>Also: Note that you could spend the same amount of computing power at guessing the private keys of other users. Finding hits there would have the possibility of getting more than the block reward.</p>

CC BY-SA 3.0
2017-11-03T12:39:55.300Z
2017-11-03T12:39:55.300Z
BlackBeltBob
<p>If you did this your uploaded block would be invalid, because the previous hash doesn't match the hash of the tallest block in the chain. Your broadcasted block would be rejected and you would have wasted the work done to produce a new block.</p>

CC BY-SA 3.0
2017-11-03T12:12:50.010Z
2017-11-03T12:12:50.010Z
Eric Allam
<p>No, because if this were possible, bitcoin would be fundamentally broken, making bounties impossible. The whole point of the mining process is to demonstrate that the hashing power was performed after the transactions were committed. Were that demonstration invalid, bitcoin transactions could not be secure and thus there could be no bounties for mining.</p>

<p>Among the many things that would stop you are the fact that mining pool work units are more than just a has and the fact that who gets the reward is <em>not</em> determined by who uploads the block.</p>

CC BY-SA 3.0
2017-11-03T18:21:19.420Z
2017-11-03T18:21:19.420Z
David Schwartz
<p>The hash you are waiting for is one of 2<sup>256</sup> values.</p>

<p>But I'm only going to use 2<sup>95</sup>, which is <strong>39,614,081,257,132,168,796,771,975,168</strong><br>
<em>(because that is the biggest 2<sup>N</sup> value I could find quickly)</em></p>

<p>Blocks are generated about every 10 minutes, so it would take about 396,140,812,571,321,687,967,719,751,680 minutes for all hashes to be generated. </p>

<p>That many minutes is approximately 75,369,256,577,496,515 <strong><em>MILLION</em></strong> Years.</p>

<p>Or, around 75 million, billion years.</p>

<p>Don't worry: You can expect your hash to come up in approximately 1/2 that time.</p>

<p>So you only have to wait 37 million-billion years.<br>
<em>(hint: The age of the universe is about 13 billion)</em></p>

<p>And remember, I did this math with 
2<sup>95</sup>.<br>
2<sup>256</sup> is much, <em>much</em>, <strong>much</strong>, <strong><em>much</em></strong> bigger.</p>

<p>Do you still think this is something to worry about?</p>

CC BY-SA 3.0
2017-11-03T21:19:04.083Z
2017-11-03T21:19:04.083Z
abelenky
<p>Theoretically speaking:
I take a random hash as a previous hash and compute whole block of hashes.
I'll wait for work on some mining pool until by some miracle this hash will be generated.
Would I get whole bounty if I upload this block straightaway?</p>

<blockchain><block>
Theoretical block prediction
Heisenbug
# Theoretical block prediction

(Asked by: username_0 on 2017-11-03)

Theoretically speaking:
I take a random hash as a previous hash and compute whole block of hashes.
I'll wait for work on some mining pool until by some miracle this hash will be generated.
Would I get whole bounty if I upload this block straightaway?

**Tags:** blockchain, block


---

## 4 answers

### Answer by username_1 on 2017-11-03. Score: 2 | Accepted answer

What you are asking is: can I create valid blocks (with only a coinbase transaction to and address of my choice) with a previous block hash that I chose at random that will be made valid if another block occurs with that hash.

Sure you can. Note that there are 2^256 hashes. The chance of finding one at random that will equal the hash of a to-be-discovered block are very very small. You would most probably just be wasting computing power/electricity/time.

Also: Note that you could spend the same amount of computing power at guessing the private keys of other users. Finding hits there would have the possibility of getting more than the block reward.


---

### Answer by username_2 on 2017-11-03. Score: 0

If you did this your uploaded block would be invalid, because the previous hash doesn't match the hash of the tallest block in the chain. Your broadcasted block would be rejected and you would have wasted the work done to produce a new block.


---

### Answer by username_3 on 2017-11-03. Score: 0

No, because if this were possible, bitcoin would be fundamentally broken, making bounties impossible. The whole point of the mining process is to demonstrate that the hashing power was performed after the transactions were committed. Were that demonstration invalid, bitcoin transactions could not be secure and thus there could be no bounties for mining.

Among the many things that would stop you are the fact that mining pool work units are more than just a has and the fact that who gets the reward is *not* determined by who uploads the block.


---

### Answer by username_4 on 2017-11-03. Score: 0

The hash you are waiting for is one of 2256 values.

But I'm only going to use 295, which is **39,614,081,257,132,168,796,771,975,168**  
*(because that is the biggest 2N value I could find quickly)*

Blocks are generated about every 10 minutes, so it would take about 396,140,812,571,321,687,967,719,751,680 minutes for all hashes to be generated.

That many minutes is approximately 75,369,256,577,496,515 ***MILLION*** Years.

Or, around 75 million, billion years.

Don't worry: You can expect your hash to come up in approximately 1/2 that time.

So you only have to wait 37 million-billion years.  
*(hint: The age of the universe is about 13 billion)*

And remember, I did this math with
295.  
2256 is much, *much*, **much**, ***much*** bigger.

Do you still think this is something to worry about?


---

