import copy

person = ['name',['saving',100]]

#浅copy
'''
p1=copy.copy(person)
p2=person[:]
p3=list(person)
'''
p1=person[:]
p2=person[:]

p1[0]='alex'
p2[0]='fengjie'
p1[1][1]=50

print(person)
print(p1)
print(p2)
# 浅copy的用处,用来创建联合账号,一个少了50,另一个也会跟着少50
