e =[ 1,2,3,4,5,6]
for a in e:
print (a)
def fun ():
y= 4+a
print (y)
a = [1, 2, 3]
def some(x):
return x**2
new_a = [some(x) for x in a]
print(new_a)
[1, 4, 9]
def my_func(x):
return(x * x)
args = [1, 2, 3, 4]
result = list(map(my_func, args))
print(result)
e =[ 1,2,3,4,5,6]
for a in e:
print (a)
def fun (_a):
y= 4+_a
return y
print(*map(fun, e))