input: Write a function to generate the first n prime numbers. If n is less than or equal to 0, return an empty list.
  assert sieve_of_eratosthenes(5) == [2, 3, 5, 7, 11]
  assert sieve_of_eratosthenes(0) == []
  assert sieve_of_eratosthenes(1) == [2]
output: def sieve_of_eratosthenes(n):
      if n <= 0:
          return []
      primes = []
      num = 2
      while len(primes) < n:
          is_prime = True
          for prime in primes:
              if num % prime == 0:
                  is_prime = False
                  break
          if is_prime:
              primes.append(num)
          num += 1
      return primes