import random lottozahlen_alle = list(range(1,50)) gewinnzahlen = random.sample(lottozahlen_alle, 6) gewinnzahlen.sort() print(gewinnzahlen)