Exercise: Primeness (for)#
Convert the program from exercise Exercise: Primeness (while) as follows.
Use a
forloop instead of awhileloopUse the
range()function to specify the range of divisor candidates
Compare both while and for solutions. Which one appears more
readable?