Pregunta de entrevista de T-Systems

write a method that filters an array and returns only N first elements