Question: For this assignment you are to implement a program that, among other things, generates lists of prime numbers. The program should begin by prompting the
For this assignment you are to implement a program that, among other things, generates lists of prime numbers. The program should begin by prompting the user to input two values. Each value should be prompted for separately. Once the two values have been input, your program should output a list of all of the prime numbers occurring between the lower of the two values and the higher of the two values inclusively. Five values should be output per line, with the exception of the last line which may have fewer than five values. Once all of the values have been output, your program should then output a count of the number of prime numbers generated, the sum of the prime numbers, and their average.
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
