非常感谢你的回复,但是g是一个generator,我这样写会提示:TypeError: can only join an iterable
回答于 2021-09-23 22:49
如果直接取数字的最大值和最小值会怎么样呢? int(max(number_list)), int(min(number_list)) 然后再进去判断能否简单一些?
回答于 2021-09-23 22:23
for num1 in range(len(list_001)): k1 = list_001[num1] k2 = list_001[num1+1] print(num1) print(k1) print(k2)
回答于 2021-09-11 21:16
lis = ['a','b','c'] for i in lis: output = i + " = {}" exec(output)
回答于 2021-08-07 15:17