查看iterator的元素
# 可以用 next(iter(list/dict)) 来查看
l = [1,2,3,4] print(next(iter(l))) # 1 d = {5:'a',6:'b'} print(next(iter(d.items()))) # (5, 'a')
# 可以用 next(iter(list/dict)) 来查看
l = [1,2,3,4] print(next(iter(l))) # 1 d = {5:'a',6:'b'} print(next(iter(d.items()))) # (5, 'a')