Physics 222 Assignment 8

Due March 21


Please turn in this assignment (and all future assignments for this course) by emailing them to me . Please use the subject of "Physics 222 HW8" for these assignments (if you use the link above, the subject will be added automatically). Please attach the source code to any programs that you write for this assignment. If you write more than one program, attach each separately. When answering the questions themselves feel free to answer directly in the body of your message (or attach your answers). I may take off points for assignments that are not sent to me in the correct form.

  1. Prime Numbers

    Write a program that finds and counts all the prime numbers between a given range of numbers. The program should have a separate function which checks to see if a given number is a prime.

    1. Include an example run of this program in your results finding the prime numbers between 2 and 1000.
    2. How many total prime numbers are there between 2 and 10000?
    3. How many prime numbers are there between 13000 and 13100?
  2. Review Problems from book:

    6.4, 6.7