擅长:python、mysql、java
<pre><code> In [23]: %cpaste
Pasting code; enter '--' alone on the line to stop.
:class ThisClass:
:
: def method1(self):
: text1 = 'iloveyou'
: return text1
:
: def method2(self):
: text2 = self.method1()
: print str(text2)
:--
In [24]: thisObj = ThisClass()
In [25]: thisObj.method2()
iloveyou
In [26]:
</code></pre>