I have a function that begins like this:
def solve_eq(string1):
string1.strip(' ')
return string1
I'm inputting the string '1 + 2 * 3 ** 4'
but the return statement is not stripping the spaces at all and I can't figure out why. I've even tried .replace()
with no luck.