What will be the output for the given python code?
import collections
dq = collections.deque([1, 2, 3])
dq.append(5)
dq.appendleft(6)
dq.extend([7])
print(list(dq))
1
[1, 2, 3, 5, 7, 6]
2
[7, 6, 1, 2, 3, 5]
3
[6, 1, 2, 3, 5, 7]
4
[1, 2, 3, 5, 6, 7]