Pergunta de entrevista da empresa Privacy.com

Given a number n, write a function that outputs the first n prime numbers.