<p>The target is adjusted every 2016 blocks but the hash of mined blocks does not have to equal the target. For the block to be valid, its hash must be <em>less than or equal to</em> the target.</p>
<p>So in that run of 2016 blocks, each block has a different output from the hash function. All are less than the target.</p>
<p>I imagine that it is incredibly unlikely that any block hash has ever exactly equalled the target.</p>

CC BY-SA 4.0
2022-07-26T18:52:06.527Z
Does difficulty target remains static for 2016 blocks in Bitcoin?
user1850484
CC BY-SA 4.0
2022-07-26T18:55:46.070Z
Yes. Since it is only recalculated every 2016 blocks, for those 2016 blocks the target is static / unchanging / the same / a constant / invariant.
RedGrittyBrick
CC BY-SA 4.0
2022-07-26T18:50:02.247Z
2022-07-26T18:54:32.050Z
2022-07-26T18:54:32.050Z
RedGrittyBrick
<p>I know that in Bitcoin the difficulty target adjust after creating 2016 blocks. So, it means that within these 2016 block the difficulty target remains same (static). Am I correct?</p>
<p>If this is correct then the miners has to find the right Hash of the header. Header=version+hash of previous blockheader+merkle tree root+timestamp+difficulty target+nonce variable.</p>
<p>Now, it seems that within these 2016 blocks the <em>input</em> (block header) to the hash function will be different but the <em>output</em> (difficulty target) remains the same. Therefore it seems to me that it breaks the property of &quot;strong collision resistance&quot; property of the hash. Am I correct? In other word, Bitcoin uses this property of the hash function to make it difficult to find solution of the puzzle.</p>

CC BY-SA 4.0
2022-07-26T18:55:39.180Z
OK. it does [not] breaks the property of "strong collision resistance" property because the  output of the hash function can be less than the target value.
user1850484
CC BY-SA 4.0
2022-07-27T12:56:22.897Z
May I remind downvoters that they *must* provide a reason why they downvoted and if they vote to close.
Hamish Gibson
<difficulty>
Does difficulty target remains static for 2016 blocks in Bitcoin?
user1850484
# Does difficulty target remains static for 2016 blocks in Bitcoin?

(Asked by: username_0 on 2022-07-26)

I know that in Bitcoin the difficulty target adjust after creating 2016 blocks. So, it means that within these 2016 block the difficulty target remains same (static). Am I correct?

If this is correct then the miners has to find the right Hash of the header. Header=version+hash of previous blockheader+merkle tree root+timestamp+difficulty target+nonce variable.

Now, it seems that within these 2016 blocks the *input* (block header) to the hash function will be different but the *output* (difficulty target) remains the same. Therefore it seems to me that it breaks the property of "strong collision resistance" property of the hash. Am I correct? In other word, Bitcoin uses this property of the hash function to make it difficult to find solution of the puzzle.

**Tags:** difficulty

> **Comments:**
> **username_0**: OK. it does [not] breaks the property of "strong collision resistance" property because the  output of the hash function can be less than the target value.  
> **username_1**: May I remind downvoters that they *must* provide a reason why they downvoted and if they vote to close.  

---

## 1 answers

### Answer by username_2 on 2022-07-26. Score: 2

The target is adjusted every 2016 blocks but the hash of mined blocks does not have to equal the target. For the block to be valid, its hash must be *less than or equal to* the target.

So in that run of 2016 blocks, each block has a different output from the hash function. All are less than the target.

I imagine that it is incredibly unlikely that any block hash has ever exactly equalled the target.

> **Comments:**
> **username_0**: Does difficulty target remains static for 2016 blocks in Bitcoin?  
> **username_2**: Yes. Since it is only recalculated every 2016 blocks, for those 2016 blocks the target is static / unchanging / the same / a constant / invariant.  

---

