154. (判断题)pop方法在省略参数的情况下,会删除列表的最后一个元素
https://www.shititong.cn/cha-kan/shiti/000dded1-b61e-ea88-c01a-2cf5d6189000.html
点击查看答案
14. (多选题)元组是置于圆括号中的一组数据,数据之间用逗号分隔,下面选项中的数据为元组类型的有:
A. ()
B. (1)
C. 1,
D. (1,2,3,4)
https://www.shititong.cn/cha-kan/shiti/000dded1-b61d-cd4b-c01a-2cf5d6189000.html
点击查看答案
51. (单选题)对于字符串的标识,Python 中可使用的方法很多,下面正确的是( )
A. " What's happened to you?"
B. ' What's happened to you?'
C. ' What\\'s happened to you?'
D. "" Oh! " It sounds terrible."
https://www.shititong.cn/cha-kan/shiti/000dded1-b61e-1db2-c01a-2cf5d6189000.html
点击查看答案
41. (单选题)ls = [25, 13, 36, 1]ls.clear()与del ls的处理结果的区别是:
A. ls.clear()只是清空列表,del ls是删除列表对象
B. ls.clear()只是删除列表对象,del ls是清空列表
C. ls.clear()与del ls的处理结果没有区别
D. ls.clear()只是清空列表,del ls是删除程序
https://www.shititong.cn/cha-kan/shiti/000dded1-b61e-072e-c01a-2cf5d6189000.html
点击查看答案
5. (多选题)遍历循环语句的结构为:Plain Textfor var in iterable:其中var为变量名;iterable为一个可迭代对象,包括哪些类型的对象?
A. 整数
B. 字符串
C. 文件对象
D. 集合、range、列表、元组
https://www.shititong.cn/cha-kan/shiti/000dded1-b61d-ba58-c01a-2cf5d6189000.html
点击查看答案
11. (多选题)s = "Hello world!"下面程序语句和注释均正确的有:
A. print(s[3:5]) # 输出 lo
B. print(s[5:3]) # 输出空字符串
C. print(s[::-1]) # 输出!dlrow olleH
D. print(s[-1::-1]) # 输出!dlrow olleH
https://www.shititong.cn/cha-kan/shiti/000dded1-b61d-c70d-c01a-2cf5d6189000.html
点击查看答案
55. (单选题)下述对元组的操作合法的是( )
A. Tuple.extend(otherTuple)
B. Tuple[0]='A'
C. Tuple.sort()
D. Tuple1+Tuple2
https://www.shititong.cn/cha-kan/shiti/000dded1-b61e-24db-c01a-2cf5d6189000.html
点击查看答案
37. (单选题)s.count(x) 的返回值是:
A. 字符串s中x的序号
B. 字符串s中x的数量
C. 字符串x中s的数量
D. 字符串x中s的序号
https://www.shititong.cn/cha-kan/shiti/000dded1-b61d-ff62-c01a-2cf5d6189000.html
点击查看答案
129. (单选题)以下()函数可以在绘制图表时,设置x轴的名称
A. xlim()
B. xlabel()
C. xticks()
D. xtitle()
解析:答案解析:
https://www.shititong.cn/cha-kan/shiti/000dded1-b61e-b88c-c01a-2cf5d6189000.html
点击查看答案
27. (多选题)以下选项中能返回集合s和t的交集的是:
A. s | t
B. s & t
C. s ^ t
D. s.intersection(t)
https://www.shititong.cn/cha-kan/shiti/000dded1-b61d-e99c-c01a-2cf5d6189000.html
点击查看答案