def odd(max : int): n = 0 while n < max: n += 1 if n % 2 != 0: yield n o = odd(5) for i in o: print(i)