I'm having trouble with ps1 problem 2. The easiest/best way to do this seems to be:
1. Take the list of primes I made in the first problem
2. log all of those primes
3. put the logs of all those primes in a list
4. take the logs list and calculate the sum of the numbers
5. print the sum
6. sum/n to calculate the ratio
7. print the ratio
Now putting that into code is a different story. I'm thinking a for statement would be best. How to I use the for statement on my previous list of primes? How do I do logs on that list of primes and stick all of those logs into a list?

Hey! We 've verified this expert answer for you, click below to unlock the details :)

I got my questions answered at brainly.com in under 10 minutes. Go to brainly.com now for free help!

Sorry, when you import math, you still need to address log as math.log(myVariable)

Looking for something else?

Not the answer you are looking for? Search for more explanations.

## More answers

Looking for something else?

Not the answer you are looking for? Search for more explanations.