num=[1,2,3,4,5,7,9]
# res=[]
# for i in num:
# res.append(i**2)
# print(res)
# def num1(array):
# res=[]
# for i in num:
# res.append(i**2)
# return res
# print(num1(num))
#终级版本
# def map_test(func,array):
# ret=[]
# for i in array:
# res=func(i)
# ret.append(res)
# return ret
# print('处理结果:',map_test(lambda x: x+1,num))
# print(map_test(lambda x: x-1,num))
# print(map_test(lambda x: x**2,num))
#map引用
# res=map(lambda x: x-1,num)
# print('内置函数map,处理结果:',res)
# print('内置函数map,处理结果:',list(res))
name='summer'
print(list(map(lambda x: x.upper(),name)))