码迷,mamicode.com
首页 > 编程语言 > 详细

20180410python笔记-Tony老师讲课

时间:2018-04-11 00:03:54      阅读:508      评论:0      收藏:0      [点我收藏+]

标签:min   invalid   syn   image   line   copy   format   nis   form   

20180410python笔记-Tony老师讲课

 

Print(‘潭州 %s%s 在上课,课堂人数 %d %(‘课堂’,’Tony’,’363’)’)

 

 

练习出错记录:

\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\

Microsoft Windows [版本 6.1.7601]

版权所有 (c) 2009 Microsoft Corporation。保留所有权利。

 

C:\Users\Administrator>python3

Python 3.6.5 (v3.6.5:f59c0932b4, Mar 28 2018, 17:00:18) [MSC v.1900 64 bit (AMD6

4)] on win32

Type "help", "copyright", "credits" or "license" for more information.

>>> print(‘潭州 %s, %s 在上课 ,课堂人数 %d‘%(‘课堂‘,‘An tony‘,3636‘‘)

  File "<stdin>", line 1

    print(‘潭州 %s, %s 在上课 ,课堂人数 %d‘%(‘课堂‘,‘An tony‘,3636‘‘)

                                                        ^

SyntaxError: invalid syntax

>>> print(‘潭州 %s, %s 在上课 ,课堂人数 %d‘%(‘课堂‘,‘Antony‘,3636‘‘)

  File "<stdin>", line 1

    print(‘潭州 %s, %s 在上课 ,课堂人数 %d‘%(‘课堂‘,‘Antony‘,3636‘‘)

                                                       ^

SyntaxError: invalid syntax

>>> print(‘潭州 %s, %s 在上课 ,课堂人数 %d‘%(‘课堂‘,‘Antony‘,‘363‘)

...

...

... ^Z

 

 

C:\Users\Administrator>python3

Python 3.6.5 (v3.6.5:f59c0932b4, Mar 28 2018, 17:00:18) [MSC v.1900 64 bit (AMD6

4)] on win32

Type "help", "copyright", "credits" or "license" for more information.

>>> print(‘潭州 %s%s 在上课,课堂人数 %d %(‘课堂’,Tony,363))

  File "<stdin>", line 1

    print(‘潭州 %s%s 在上课,课堂人数 %d %(‘课堂’,Tony,363))

            ^

SyntaxError: invalid character in identifier

>>> a

 

先继续听

Print(“tony1+tony2 :”,tony1+tony2)

Print(“tony1*2 :”,tony1*2)

Print(tony1

 

def find(self, sub, start=None, end=None)

 

\\\开始索引,结束索引

 

 技术分享图片

print (‘潭州’)

 

 

继续听课

 

技术分享图片

 

20180410python笔记-Tony老师讲课

标签:min   invalid   syn   image   line   copy   format   nis   form   

原文地址:https://www.cnblogs.com/kpboaten27/p/8783102.html

(0)
(1)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!