input: Write a python function to print names and ages from a list of dictionaries.
  assert print_names_and_ages([{'name': 'Alice', 'age': 30}, {'name': 'Bob', 'age': 25}]) == "Name: Alice\nAge: 30\nName: Bob\nAge: 25"
  assert print_names_and_ages([{'name': 'Charlie', 'age': 40}, {'name': 'David', 'age': 35}]) == "Name: Charlie\nAge: 40\nName: David\nAge: 35"
  assert print_names_and_ages([{'name': 'Eve', 'age': 22}]) == "Name: Eve\nAge: 22"
output: def print_names_and_ages(people):
      result = []
      for person in people:
          result.append(f"Name: {person['name']}\nAge: {person['age']}")
      return "\n".join(result)