Function call - Printable Version +- Python Forum (https://python-forum.io) +-- Forum: Python Coding (https://python-forum.io/forum-7.html) +--- Forum: Homework (https://python-forum.io/forum-9.html) +--- Thread: Function call (/thread-7238.html) |
Function call - Antonio_Gallardo - Dec-29-2017 I have a very simple question. I need a function that calls two functions. I have been trying with "add (function1 , function2)" but it doesn't work. One fucntion returns a string value and the other a numeric. Thanks and sorry for not being able to specify more. RE: Function call - nilamo - Dec-29-2017 (Dec-29-2017, 09:56 PM)Antonio_Gallardo Wrote: but it doesn't work. What does that mean? Is there an error? RE: Function call - Terafy - Dec-29-2017 missing round brackets add (function1() , function2())also you need to change the string to a numeric when you add them. RE: Function call - Larz60+ - Dec-29-2017 or if trying to add: result = function1() + function2() print(result) # or simply print(function1() + function2()) |