def askinput(): a = input() return a def main(): print("enter input") l1 = list() value = 0 while value != 42: value = int(askinput()) l1.append(value) for i in l1: print(i) main()
can anybody please say what is wrong?
Got it guys, thanks
def askinput(): a = input() return a def main(): l1 = list() value = 0 while value != 42: value = int(askinput()) l1.append(value) l = len(l1) - 1 for i in range(0,l): print(l1[i]) main()
Hello, need to indent: follow the link with your indented code: https://repl.it/repls/AzureIndolentLogic