Skip to content

Instantly share code, notes, and snippets.

View stefanopepe's full-sized avatar
💭
Back at some random coding. Cool thing, somehow it works!

Stefano Pepe stefanopepe

💭
Back at some random coding. Cool thing, somehow it works!
  • Nassau, Bahamas
  • 16:17 (UTC -04:00)
View GitHub Profile
@stefanopepe
stefanopepe / hashcash.py
Created October 26, 2020 17:02 — forked from i3visio/hashcash.py
hashcash.py is a clean implementation of a "proof of work" library for Python.
# ----------------------------------------------
# hashcash.py: Hashcash implementation
# ----------------------------------------------
"""
Hashcash is a "proof of work."
Example:
>>> import sha
>>> sha.new('denmark2890CF').hexdigest() '000000cf89643370c24e413ec0886ab92bd7f6e8'