课程
/后端开发
/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程序
购课补贴联系客服咨询优惠详情
慕课网APP您的移动学习伙伴
扫描二维码关注慕课网微信公众号