The study of literation in Python(20170911)
number = {1,2,3,4} # this is dict
for k in number:# the literation function in Python
print(k)
char = ‘abcd’
for key in char:
print(key)
the enumerate() function can change the list to the index-element
example
for i,value in enumerate([‘a’,’b’,’c’]):
print(i,value)# 0 a, 1 b, 2 c
for x,y in [(1,2),(2,3),(3,4)]:
print(x,y)