Nguyễn Ngọc Huỳnh
New member
What will be the output of the following Python code?
A.
2, -2
4, -4
6, -6
B. [(2, -2), (4, -4), (6, -6)]
C.
(2, -2)
(4, -4)
(6, -6)
D. [-4, -16, -36]
Code:
l1=[2,4,6]
l2=[-2,-4,-6]
for i in zip(l1, l2):
print(i)
2, -2
4, -4
6, -6
B. [(2, -2), (4, -4), (6, -6)]
C.
(2, -2)
(4, -4)
(6, -6)
D. [-4, -16, -36]