Simply type it out:
>>> a,b,c,d = [1,2,3,4]
>>> a
1
>>> b
2
>>> c
3
>>> d
4
Python employs assignment unpacking
when you have an iterable
being assigned to multiple variables like above.
In Python3.x
this has been extended, as you can also unpack to a number of variables that is less than the length of the iterable
using the star operator:
>>> a,b,*c = [1,2,3,4]
>>> a
1
>>> b
2
>>> c
[3, 4]
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…