On January 7, 2016, it was confirmed that a new record large prime was discovered: 2^274,207,281-1 with 22,338,618 digits! This discovery is thought to be the 49th Mersenne prime since is can be expressed as (2^x)-1. See also https://www.youtube.com/watch?v=q5ozBnrd5Zc In honor of this discovery, create a program that generates a list of the first 1000 prime numbers. Remember that 1 is not prime. You can only start with the information that 2 is the first prime number; everything else must be calculated! Here's a list of the first 1000 primes: https://primes.utm.edu/lists/small/1000.txt The 1000th prime is 7919.
The extra sprite is a blurred version of the solution. Note that it isn't very long. The solution uses three variables and one list. Two of these four objects are included in this template. Feel free to delete this image. Hint: To find individual small primes trial division works well. To test n for primality (to see if it is prime) just divide by all of the primes less than the square root of n. For example, to show is 211 is prime, we just divide by 2, 3, 5, 7, 11, and 13. ** Generate the list of primes and use this list of primes to test larger numbers for primality! ** Also, there are no even primes besides 2, and no primes ending in a 5 or 0, except 5. Finally, run your program in Turbo Mode for faster results.