Fast Enterprises interview question

How to code a function to find prime numbers.