Python code makes it really simple:
Code:
def checkwork(block, difficulty_rep):
s = hashlib.sha256(block.decode('hex'))
val = int(s.hexdigest(), 16)
diff = int(difficulty_rep, 16)
return val < diff
Bitcoin Forum |
October 06, 2024, 07:37:11 PM | |||
|
News: Latest Bitcoin Core release: 28.0 [Torrent] |
Home | Help | Search | Login | Register | More |
|