Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

blockchain.py

from hashlib import sha256
x = 5
y = 0  # We don't know what y should be yet...
while sha256(f'{x*y}'.encode()).hexdigest()[-1] != "0":
    y += 1
print(f'The solution is y = {y}')
Source by hackernoon.com #
 
PREVIOUS NEXT
Tagged:
ADD COMMENT
Topic
Name
3+8 =