I am just trying to get this done for a project I am doing. I want to jsu parse/loop through a string of letters and numbers but I would like to just add the numbers to a list and convert them to integers.
x = "hello123"
myList = []
def func():
for i in x:
if int in mylist:
print(mylist)
i = int(i)
myList.append(i)
func()
I just need it to add the 123 to a list and make them integers.