input: Write a function to create a basic blockchain system in Python. The function should include a hashing function, a class for blocks, and a class for the blockchain itself. The output of the function should return the entire blockchain in JSON format.
  assert create_blockchain()['chain'] == []
  assert create_blockchain().add_block({'timestamp': '2023-10-05', 'data': 'First block'}) == None
  assert json.loads(create_blockchain().get_chain())['chain'][0]['index'] == 0
output: def create_blockchain():
      import hashlib
      import json
      import time
  
      class Block:
          def __init__(self, index, previous_hash, timestamp, data, hash):
              self.index = index
              self.previous_hash = previous_hash
              self.timestamp = timestamp
              self.data = data
              self.hash = hash
  
      class Blockchain:
          def __init__(self):
              self.chain = []
              self.create_genesis_block()
  
          def create_genesis_block(self):
              genesis_block = Block(0, "0", time.time(), "Genesis Block", self.hash_block(0, "0", time.time(), "Genesis Block"))
              self.chain.append(genesis_block)
  
          def get_latest_block(self):
              return self.chain[-1]
  
          def add_block(self, data):
              latest_block = self.get_latest_block()
              new_index = latest_block.index + 1
              new_timestamp = time.time()
              new_hash = self.hash_block(new_index, latest_block.hash, new_timestamp, data)
              new_block = Block(new_index, latest_block.hash, new_timestamp, data, new_hash)
              self.chain.append(new_block)
  
          def hash_block(self, index, previous_hash, timestamp, data):
              block_string = f"{index}{previous_hash}{timestamp}{data}".encode()
              return hashlib.sha256(block_string).hexdigest()
  
          def get_chain(self):
              chain_data = []
              for block in self.chain:
                  chain_data.append({
                      'index': block.index,
                      'previous_hash': block.previous_hash,
                      'timestamp': block.timestamp,
                      'data': block.data,
                      'hash': block.hash
                  })
              return json.dumps({'chain': chain_data}, default=str)
  
      return Blockchain()