在terminal输入: hi = 'name' dir(hi) # 会返回 hi 对象所有的相关方法,属性 http://isilic.iteye.com/blog/1733560 转载于:https://www.cnblogs.com/terryc/p/5063689.html