[Tutor] help beginner in python.
Krystle Scott
madpotential at gmail.com
Sun Feb 24 22:25:25 CET 2008
i need to write an algorithm for computing square roots.
so far I have
import math
def main ():
print " This program computes approximate square roots using Newton's
method: "
print
input = (" Enter whose square root you wish to compute (a) : ")
input = (" Enter the number of iterations :" )
discRoot = math.sqrt
print
print "The solutions of the square roots"
I need to have it print out iterations and math.sqrt what am i doing wrong?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.python.org/pipermail/tutor/attachments/20080224/1f8f9411/attachment.htm
More information about the Tutor
mailing list