I want to disable the "return" from printing any object that it returns to the python shell.
For example, the python script test.py example looks like this:
def func1():
list = [1,2,3,4,5]
print list
return list
Now, if I do the following:
python -i test.py
>>>func1()
This always gives me two fingerprints on the python shell. I just want to print and get the returned object.
rajan
source
share