Question: using python Problem 1 Write a program that computes and prints the 1000th prime number. Problem 2 Write a program that computes the sum of

using python

Problem 1

Write a program that computes and prints the 1000th prime number.

Problem 2

Write a program that computes the sum of the logarithms of all the primes from 2 to some number n, and print out the sum of the logs of the primes, the number n, and the ratio of these two quantities. Test this for different values of n.

You should be able to make only some small changes to your solution to Problem 1 to solve this problem as well.

Hints: While you should see the ratio of the sum of the logs of the primes to the value n slowly get closer to 1, it does not approach this limit monotonically.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!