Fast Enterprises interview question

Prime Number Generator coding question