Loop Python melalui daftar
list = [1, 3, 6, 9, 12]
for i in list:
print(i)
Grepper
list = [1, 3, 6, 9, 12]
for i in list:
print(i)
colors = ["red", "green", "blue", "purple"]
i = 0
while i < len(colors):
print(colors[i])
i += 1
my_list = ["Hello", "World"]
for i in my_list:
print(i)
for i in range(len(Latitudes)):
Lat,Long=(Latitudes[i],Longitudes[i])
lst = [10, 50, 75, 83, 98, 84, 32]
res = list(map(lambda x:x, lst))
print(res)
for fruit in ['apple','banana','mango']:
print("I like",fruit)