Question: In Python 3, which of the following function removes all leading and trailing whitespace in string?
A: replace(old, new [, max])
B: strip([chars])
C: swapcase()
D: title()
Please eliminate two incorrect options first, then think it step by step and choose the most proper one option.