Обновление файла PoW.py
This commit is contained in:
parent
7297fe9805
commit
6a4c6d3b7e
2
PoW.py
2
PoW.py
@ -2,7 +2,7 @@ import hashlib
|
|||||||
|
|
||||||
def check(data, proof, complexity=1, f=hashlib.sha256):
|
def check(data, proof, complexity=1, f=hashlib.sha256):
|
||||||
zeros="0"*complexity
|
zeros="0"*complexity
|
||||||
hash=f(data+proof)
|
hash=f(proof+data)
|
||||||
hashdata=hash.hexdigest()
|
hashdata=hash.hexdigest()
|
||||||
b=0
|
b=0
|
||||||
for a in hashdata:
|
for a in hashdata:
|
||||||
|
Loading…
Reference in New Issue
Block a user