代码
提交代码
a = [1, 2, 3] b = [10, 20, 30] # 打印输出列表 a 的相关信息 print('length of list is %d' % len(a)) i = 0 while i < len(a): print(a[i]) i = i + 1 # 打印输出列表 b 的相关信息 print('length of list is %d' % len(b)) i = 0 while i < len(b): print(b[i]) i = i + 1
运行结果