module object not callable

Joined
30 Nov 2005
Posts
12,691
getting this error from a python module

Code:
Traceback (most recent call last):
  File "/home/jay/Python scripts/precon2010.py", line 27, in <module>
    res = calc(amt,total)
TypeError: 'module' object is not callable



Code:
from __future__ import division

def calc(amt,total):

    s=[]
    for i in range(len(amt)):
        s.append((amt[i]/sum(amt))*total)

    return s

it was working yesterday but I don't know what I have changed to break it.
 
Top