HARMAN interview question

Write code to find if a number is prime.