PROBLEM SET
题库
按难度与知识点筛选,找到适合的练习题。
题目列表
共 67434 题
A32003
执行下面Python代码后,输出的结果不可能是89781。( )import randomi = 1s = ""while i <= 5: a = random.randint(0, 9) if a % 3 == (i + 1) % 3: s += str(a) i += 1print(s)
Python-L3
中等
--
A32004
执行下面Python代码后,输出的结果是8。a = 0b1010b = 0o1100c = a & bprint(c)
Python-L3
中等
--
A32005
a,b为整数,如果表达式 a ^ b == 0 为True,那么说明a与b相等。
Python-L3
中等
--
A32006
十六进制FB 转成八进制为363。
Python-L3
中等
--
A32007
整数-6的16位补码可用十六进制表示为FFFA。
Python-L3
中等
--
A32008
集合支持索引操作,可以通过索引访问元素。
Python-L3
中等
--
A32012
某小学男子篮球队招募新成员,要求加入球队的成员身高在135厘米以上(不含135厘米)。本次报名的人 员有10人,她们的身高分别是125、127、136、134、137、138、126、135、140、145。完善以下代码,求出本次球队能够招募到新成员的人数?( )a = [125, 127, 136, 134, 137, 138, 126, 135, 140, 145]b = [i > 135 …
Python-L3
中等
--
A32014
执行下面Python代码后,输出的结果可能是?( )str="Happy new year"a = set(str)print(a)
Python-L3
中等
--
A32015
执行下面Python代码后,输出的结果是?( )s = 'gesp.ccf.org.cn'print(s.split('.', 1))
Python-L3
中等
--
A32017
执行下面Python代码后,输出的结果是?( )a = ['o', 'r', 'a', 'n', 'g', 'e']A.a.sort()B.a.reverse()C.print(a)
Python-L3
中等
--
A32018
执行下面Python代码后,输出的结果是?( )a = [i % 10 for i in range(10, 20)]b, c = [], []while len(a) > 0: s = a.pop() if s % 2 == 0: b.append(s) else: c.append(s)print(b, c)
Python-L3
中等
--
A32019
执行下面Python代码后,输出的结果是?( )t1 = (1, 2, 3, 4, 5, 6, 7)t2 = ('a', 'b', 'c', 'd', 'e', 'f')s = t1[2:] + t2[5:2:-1]print(s)
Python-L3
中等
--
A32020
执行下面Python代码后,输出的结果是?( )t1 = ("python", "c++", "scratch")t2 = tuple(i for i in t1[::-1])print(t2)
Python-L3
中等
--
A32021
执行下面Python代码后,输出的结果不可能是哪一项?( )a = dict(zip(range(8, 0, -2), range(0, 8, 2)))print(a)
Python-L3
中等
--
A32022
执行下面Python代码后,输出的结果是?( )a = {'name': 'Tom', 'age': 12}b = {'name': 'Join', 'email': 'join@qq.com'}b.update(a)print(len(b))
Python-L3
中等
--
A32023
将十进制2024转化成八进制,可以使用下列哪个表达式?( )
Python-L3
中等
--
A32024
下列流程图的输出结果是?( )
Python-L3
中等
--
A32025
下面流程图在yr输入2024时,可以判定yr代表闰年,并输出 2月是29天 ,则图中菱形框中应该填入( )。
Python-L3
中等
--
A32027
计数
Python-L2
较易
--
A32028
平方之和
Python-L2
较易
--