a = " yo! " b = a.strip() # this will remove the white spaces that are leading and trailing
Here is what the above code is Doing:
1. We create a variable called a and set it equal to a string with leading and trailing spaces.
2. We create a variable called b and set it equal to the variable a with the leading and trailing spaces removed.
3. We print the variable b.