you can also import a set of functions that are inside math and then drop the "math." prepending
from math import sqrt, exp, log, pow
you can also import all functions that are inside math
from math import *
I would do the middle version. The first is indeed too verbose. The last imports lots of stuff, and maybe it import some "bs" function who's name clashes with a function you made yourself. With the middle one you'll have an explicit list of functions you've imported from math.