input: Write a function to generate a list that contains numbers from 0 to 9 using a while loop in Python and appending the current number to the list. The function should print the resulting list. Define the function header as: def generate_list():
  
  assert generate_list() == [0, 1, 2, 3, 4, 5, 6, 7, 8, 9]
output: def generate_list():
      result = []
      i = 0
      while i < 10:
          result.append(i)
          i += 1
      print(result)