I have a little homework assignment where I am supposed to return any given number of prime elements in an array.
Here is my code:
I'm a little confused because 65 is being output as a prime number. The correct output should be 43 and 41. I know that 65 isn't prime, but rather a composite number. I've been at this for a while but I can't quite think it out without getting stuck. Any feedback would be appreciated!