[Tutor] How can a function know where it was called from
Ben Vinger
benvinger at googlemail.com
Thu Mar 2 11:25:19 CET 2006
Hello
I want myfunction in the pseudocode below return something different if it
was called from indexfunction.
def indexfunction():
blah
def myfunction():
x = 'whatever'
if <myfunction was called from indexfunction>:
return x
else:
return <header> + x + <footer>
Thanks
Ben
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.python.org/pipermail/tutor/attachments/20060302/adc18e1e/attachment.htm
More information about the Tutor
mailing list