クラスを呼び出すと自動で、クラス内の処理[関数1,関数2]を実行したいと思います。
python
1class Hello(): 2 3 @classmethod 4 def Sain(self): 5 return "Hello world" 6 7 def Bain(self): 8 return "NO Thank" 9 10 return Sain(),Bain() 11 12 13print( Hello() )
Helloクラスを呼び出した返り値がSainとBainの実行結果
#エラー内容
TabError: inconsistent use of tabs and spaces in indentation
回答2件
あなたの回答
tips
プレビュー
バッドをするには、ログインかつ
こちらの条件を満たす必要があります。