Is this exactly how it shows in your shell? If so, it seems you need to indent your methods.
#**************************************** import math def area(radius): return math.pi * radius**2 def circumference(radius): return 2 * math.pi * radius #**************************************** *Matt Jones* On Mon, Feb 18, 2013 at 1:42 PM, leonardo selmi <l.se...@icloud.com> wrote: > pls i need help: > > i have copied the following from a book and tried to make it work: > > import math > > def area(radius): > return math.pi * radius**2 > > def circumference(radius): > return 2 * math.pi * radius > > i saved the above program from python shell into a file as "circle.py" . > when i type "import circle" i get error.. > > > kind regards > -- > http://mail.python.org/mailman/listinfo/python-list >
-- http://mail.python.org/mailman/listinfo/python-list