I looked online and every method for extracting numbers from strings uses the
[int(word) for word in a_string.split() if word.isdigit()]
method,
however when I run the code below, it does not extract the number 45
test = "ON45"
print(test)
print([int(i) for i in test.split() if i.isdigit()])
This is what python prints
ON45
[]
The second list is empty, it should be [45]
which I should be able to access as integer using output_int = test[0]