Anyone know how I can find the character in the center that is surrounded by spaces?
1 + 1
I think you are looking for something like the
split() method which will split on white space by default.
Suppose we have a string
s = "1 + 1" chunks = s.split() print(chunks) # Will print '+'