input: Write a function to create a basic blockchain in Python using only the core modules. The function should initialize the blockchain with an initial block and provide methods to create new blocks and hash existing blocks. Return the initialized blockchain object.
  assert initialize_blockchain()==<__main__.Blockchain object at 0x...>
  assert initialize_blockchain().chain[0]['block_number']==1
  assert len(initialize_blockchain().chain[0])==4
output: 
  def initialize_blockchain():
      import hashlib
      import time
  
      class Blockchain:
          def __init__(self):
              self.chain = []
              self.create_block(proof=1, previous_hash='0')
  
          def create_block(self, proof, previous_hash):
              block = {
                  'block_number': len(self.chain) + 1,
                  'timestamp': time.time(),
                  'proof': proof,
                  'previous_hash': previous_hash
              }
              self.chain.append(block)
              return block
  
          def hash(self, block):
              encoded_block = str(block).encode()
              return hashlib.sha256(encoded_block).hexdigest()
  
      return Blockchain()
  