I have a function and I\'m making another one in which I need to call the first function. I don\'t have experience in Python, but I know that in languages like MATLAB it\'s
If, and only if, you have the square
function defined in a square
module, then you should look to import the simple name from it instead.
from square import square
If you don't want to change anything, then you need to use its fully qualified name:
something = square.square(y) + square.square(z)
The module's name is square
, and you can't call functions on modules.