input: Write a function that takes a list of integers and returns the sublist consisting of the prime numbers from the list. The function should return an empty list if there are no prime numbers. If the input list is empty, return an empty list as well.
  
  def is_prime(num):
      if num <= 1:
          return False
      for i in range(2, int(num**0.5) + 1):
          if num % i == 0:
              return False
      return True
  
  def prime_list(lst):
      prime_lst = []
      for num in lst:
          if is_prime(num):
              prime_lst.append(num)
      return prime_lst
  
  assert prime_list([2, 8, 3, 6, 10, 7, 14, 11, 17, 15]) == [2, 3, 7, 11, 17]
  assert prime_list([4, 6, 8, 9, 10]) == []
  assert prime_list([]) == []
output: def prime_list(lst):
      prime_lst = []
      for num in lst:
          if is_prime(num):
              prime_lst.append(num)
      return prime_lst