Neuer Kurs! Jeder Programmierer sollte generative KI lernen!
Kostenlose Lektion ausprobieren0
How to print a,b,c values by using custom generator
How to print a,b,c values by using custom generator
1 Antwort
+ 2
myiterator = (c for c in "abc")
for i in range(3):
print(next(myiterator))
use a list or another iterable instead of "abc"