|
Size: 633
Comment:
|
← Revision 6 as of 2011-02-16 13:07:00 ⇥
Size: 1098
Comment:
|
| Deletions are marked like this. | Additions are marked like this. |
| Line 5: | Line 5: |
=== Creating Integer Objects === {{{ #!python >>> a = 1 >>> a 1 >>> type(a) <type 'int'> >>> b = int(1) >>> b 1 >>> type(b) <type 'int'> }}} |
|
| Line 47: | Line 62: |
=== staticmethod vs. classmethod === {{{ #!python >>> class C: ... a=1 ... @staticmethod ... def temp(): ... print C.a ... >>> C.temp() 1 >>> class C: ... a=1 ... @classmethod ... def temp(cls): ... print cls.a ... >>> C.temp() 1 }}} |
Note : This is an experimental page, Python can be learned interactively from a prompt, and learning by observations is a good habit, so this page. -- BaijuMuthukadan
(This page is not linked from main pages yet.)
Creating Integer Objects
__del__ workings
list append and assignment
