"Kirk Z Bailey" <kbai...@howlermonkey.net> wrote
som quadratic equation work. This involves squareroots. So I fired uop the interactive idle and imported math. I then tried to play with sqrt.

Nothing.

Importing math does not import a sqrt function.

So what error do you get? Please post it.

Did you try dir(math) to see the list of names? Does it include sqrt?
If the list is not as you expect have you perhaps inadvertantly created a file called math.py that it is importing instead?

Now riddle me this: if string.foo makes it do a function FOO on a string, whyfore and howcome does math.sqrt not do square roots on a simple number like 4???

It does on my system.

--
Alan Gauld
Author of the Learn to Program web site
http://www.alan-g.me.uk/

_______________________________________________
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor

Reply via email to