built-in pow() vs. math.pow()

Dennis Lee Bieber wlfraed at ix.netcom.com
Thu Mar 30 15:49:54 EDT 2023


On Thu, 30 Mar 2023 19:22:53 +0200, Roel Schroeven <roel at roelschroeven.net>
declaimed the following:

>Either import the things you need explicitly: "from math import sin, 
>cos, exp" (for example).
>Or a plain import: "import math" combined with "math.sin", "math.cos".
>Or use an abbreviation: "import math as m" combined with "m.sin", "m.cos".

	Or, for this particular example of not wanting math.pow...

>>> from math import *
>>> pow(3, 4)
81.0
>>> del pow
>>> pow(3, 4)
81
>>> 


More information about the Python-list mailing list