最贊回答 / 慕粉4438442
我找到問題了,語句中的or 應(yīng)該是and既不是整數(shù)型,也不是浮點(diǎn)數(shù)我發(fā)現(xiàn)講課老師的一個bug了
2020-09-10
已采納回答 / qq_慕少3205394
template='Life?is?short,you?need?{P}' P='python' result=template.format(P=P) print(result)P相當(dāng)于占位符,沒有給他賦值
2020-09-08
已采納回答 / 慕先生5347740
我覺得這是imooc的IDE本身的問題,我在命令行和python的編輯器中嘗試了之后,print('hello',?'python') 打印出來的就是hello,python
2020-09-06