I hope my question does not sound too silly - but is it good programming practice to use return and print statement one after the other in the same function in Python?
e.g.
def test():
...
if retval < 0:
errval = "Error in reading value"
print errval
return errval
'errval' is being used by another function, and it also has to be printed. Any advice would be appreciated, thanks!
raisean exception with a descriptive name instead?