DescentBB
http://www.descentbb.net/

[python] TIL how to use __doc__ and help()...
http://www.descentbb.net/viewtopic.php?f=7&t=20105
Page 1 of 1

Author:  Isaac [ Sun Dec 09, 2012 4:22 pm ]
Post subject:  [python] TIL how to use __doc__ and help()...

example:
gtk.Window().__doc__

help(["a","b","c"])

Author:  Jeff250 [ Sun Dec 09, 2012 6:00 pm ]
Post subject:  Re: TIL how to use __doc__ and help()... these are important

To create documentation:
Code:
>>> def add(a, b):
...     '''Given two numbers a and b, returns a + b.'''
...     return a + b
...
>>> add.__doc__
'Given two numbers a and b, returns a + b.'
>>> help(add)

Author:  Isaac [ Tue Dec 11, 2012 12:41 am ]
Post subject:  Re: TIL how to use __doc__ and help()... these are important

I better get into the habit of doing that if I'm going to start putting stuff on launchpad

Page 1 of 1 All times are UTC-06:00
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
http://www.phpbb.com/