def proof_of_work(last_proof):
    "\n    Simple Proof of Work Algorithm\n    - Find a number p' such that hash(pp') contains 6 leading\n    zeroes, where p is the previous p'\n    - p is the previous proof, and p' is the new proof\n    "
    print(f'''
Search for proof initialized.
''')
    proof = 0
    while (valid_proof(last_proof, proof) is False):
        proof += 1
    print(f'''
Search for proof complete, proof is {proof}
''')
    return proof
Simple Proof of Work Algorithm
- Find a number p' such that hash(pp') contains 6 leading
zeroes, where p is the previous p'
- p is the previous proof, and p' is the new proof
def proof_of_work(last_proof):
    "\n    Simple Proof of Work Algorithm\n    - Find a number p' such that hash(pp') contains 6 leading\n    zeroes, where p is the previous p'\n    - p is the previous proof, and p' is the new proof\n    "
    print(f'
Search for proof initialized.
')
    proof = 0
    while (valid_proof(last_proof, proof) is False):
        proof += 1
    print(f'
Search for proof complete, proof is {proof}
')
    return proof