-1
A
回答
3
只是dir(whateverobject)
。例如:
Python 3.1rc1 (r31rc1:73141, Jun 2 2009, 12:50:02)
[GCC 4.0.1 (Apple Inc. build 5493)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> x=23
>>> dir(x)
['__abs__', '__add__', '__and__', '__bool__', '__ceil__', '__class__', '__delattr__', '__divmod__', '__doc__', '__eq__', '__float__', '__floor__', '__floordiv__', '__format__', '__ge__', '__getattribute__', '__getnewargs__', '__gt__', '__hash__', '__index__', '__init__', '__int__', '__invert__', '__le__', '__lshift__', '__lt__', '__mod__', '__mul__', '__ne__', '__neg__', '__new__', '__or__', '__pos__', '__pow__', '__radd__', '__rand__', '__rdivmod__', '__reduce__', '__reduce_ex__', '__repr__', '__rfloordiv__', '__rlshift__', '__rmod__', '__rmul__', '__ror__', '__round__', '__rpow__', '__rrshift__', '__rshift__', '__rsub__', '__rtruediv__', '__rxor__', '__setattr__', '__sizeof__', '__str__', '__sub__', '__subclasshook__', '__truediv__', '__trunc__', '__xor__', 'bit_length', 'conjugate', 'denominator', 'imag', 'numerator', 'real']
請告訴我們什麼是不適合你 - 給我們一個機會來幫助!
相關問題
- 1. 如何在Rails 3.1中使用belongs_to關係的屬性?
- 2. raw_input()在python 3.1中已棄用?
- 3. 如何在Python 3.1中執行windows API調用?
- 4. 如何在kohana中調用過程3.1
- 5. 在本地屬性文件中覆蓋Spring 3.1中的屬性
- 6. Python:如何覆蓋方法調用中的數據屬性?
- 7. 如何調用調用類的屬性
- 8. 如何在__init__中設置python屬性
- 9. 如何在Python類中設置屬性
- 10. Easy Python ASync。預編譯器?
- 11. 嵌套屬性在Rails的節省3.1
- 12. 如何將屬性文件中的spring 3.1 classNameString轉換爲類?
- 13. 如何在VS2013 Cordova應用程序中使用angularjs調用azure easy API?
- 14. 調用屬性
- 15. 如何調用從另一個類(Python)的特定屬性
- 16. Python:如何使對象屬性參考調用方法
- 17. 如何調用特定的未知Python對象屬性?
- 18. Python:如何用常規屬性替換屬性?
- 19. Python:如何用getattr獲取對象屬性的屬性?
- 20. 如何使用對象的屬性... Python!
- 21. Python中的屬性引用
- 22. 如何訪問深JSON在Python屬性
- 23. 如何拉DIV與BeautifulSoup屬性在Python
- 24. 如何在python刪除屬性錯誤
- 25. 我如何處理Python中的屬性?
- 26. python中的類,如何設置屬性
- 27. 如何提取python中的屬性值?
- 28. 如何在JavaScript中使用Rails 3.1調用View Helper方法
- 29. 如何在Python中調試win32com調用
- 30. 如何調用HTML Helper的屬性?
它不適用於3.1? – SilentGhost 2009-06-07 21:46:07