input: Write a function that generates a histogram in Python using the provided data. The function should use matplotlib to plot the histogram and should include appropriate labels for the x-axis and y-axis, as well as a title. If the data is empty, the function should return without plotting anything.
  def generate_histogram(data):
      if not data:
          return
      import matplotlib.pyplot as plt
      plt.hist(data, bins = [0, 20, 40, 60, 80, 100, 120, 140, 160], edgecolor = 'black') 
      plt.xlabel('Range of values') 
      plt.ylabel('Number of Occurrences') 
      plt.title('Histogram of data') 
      plt.show()
  assert generate_histogram([3, 5, 7, 2, 8, 10, 11, 65, 72, 81, 99, 100, 150]) == None
  assert generate_histogram([1, 2, 3, 4, 5]) == None
  assert generate_histogram([]) == None
output: def generate_histogram(data):
      if not data:
          return
      import matplotlib.pyplot as plt
      plt.hist(data, bins=[0, 20, 40, 60, 80, 100, 120, 140, 160], edgecolor='black')
      plt.xlabel('Range of values')
      plt.ylabel('Number of Occurrences')
      plt.title('Histogram of data')
      plt.show()