input: Write a function that implements a hash table in Python that supports insert, delete, and retrieve operations. The hash table should use chaining to handle collisions and have a fixed size of 256 slots.
  
  class HashTable:
      def __init__(self):
          self.table = [[] for _ in range(256)]
   
      def insert(self, key, value):
          h = hash(key) % 256
          for i, kv in enumerate(self.table[h]):
              if kv[0] == key:
                  self.table[h][i] = (key, value)
                  return
          self.table[h].append((key, value))
   
      def retrieve(self, key):
          h = hash(key) % 256
          for kv in self.table[h]:
              if kv[0] == key:
                  return kv[1]
   
      def delete(self, key):
          h = hash(key) % 256
          for i, kv in enumerate(self.table[h]):
              if kv[0] == key:
                  del self.table[h][i]
  
  # Test cases
  hash_table = HashTable()
  hash_table.insert("key1", "value1")
  assert hash_table.retrieve("key1") == "value1"
  hash_table.insert("key1", "newValue1")
  assert hash_table.retrieve("key1") == "newValue1"
  hash_table.delete("key1")
  assert hash_table.retrieve("key1") is None
output: def __init__(self):
      self.table = [[] for _ in range(256)]
  
  def insert(self, key, value):
      h = hash(key) % 256
      for i, kv in enumerate(self.table[h]):
          if kv[0] == key:
              self.table[h][i] = (key, value)
              return
      self.table[h].append((key, value))
  
  def retrieve(self, key):
      h = hash(key) % 256
      for kv in self.table[h]:
          if kv[0] == key:
              return kv[1]
  
  def delete(self, key):
      h = hash(key) % 256
      for i, kv in enumerate(self.table[h]):
          if kv[0] == key:
              del self.table[h][i]