課程
/后端開發
/Python
/初識Python
print r''' free and easy to learn.Let's start learn''''三重單引號,一個字符串未尾有一個單引號,這里Pychon無法識別? 該怎么處理
2016-08-09
源自:初識Python 3-6
正在回答
print r''' free and easy to learn.Let's start learn''' '你的這段代碼,在加粗的部分就已經結束了,多出來的一個',所以就會報錯,這應該能知道為什么了..
print r''' free and easy to learn.Let's start learn' ''',這樣就可以,親測,在單引號和三重引號中間加一個空格
print?r'''?free?and?easy?to?learn.Let's?start?learn'?'''
我是多打了一個空格。。。不知道能不能解決你的問題。
print r''' free and easy to learn.Let's start learn''''
最后四個單引號是怎么回事……
舉報
學python入門視頻教程,讓你快速入門并能編寫簡單的Python程序
Copyright ? 2025 imooc.com All Rights Reserved | 京ICP備12003892號-11 京公網安備11010802030151號
購課補貼聯系客服咨詢優惠詳情
慕課網APP您的移動學習伙伴
掃描二維碼關注慕課網微信公眾號
2016-10-12
print r''' free and easy to learn.Let's start learn''' '你的這段代碼,在加粗的部分就已經結束了,多出來的一個',所以就會報錯,這應該能知道為什么了..
2016-08-09
print r''' free and easy to learn.Let's start learn' ''',這樣就可以,親測,在單引號和三重引號中間加一個空格
2016-08-09
我是多打了一個空格。。。不知道能不能解決你的問題。
2016-08-09
print r''' free and easy to learn.Let's start learn'
'''
2016-08-09
最后四個單引號是怎么回事……