0

What does this Python function definition mean? I don't recognize the syntax. It doesn't look like any function definition I have ever seen, with the colons, and the -> after the parenthesis.

def new_block(self, proof: int, previous_hash: Optional[str]) -> Dict[str, Any]:

I saw this function definition here: https://github.com/dvf/blockchain/blob/master/blockchain.py

Chris Nielsen
  • 839
  • 1
  • 16
  • 31

0 Answers0