Let's try to differentiate between some kinds of honorifics. Write a regular expression in the variable template in such a way that it would match the following strings:
- Mr Smith
- Mr. Smith
- Ms Smith
- Ms. Smith
Note that your template should not match any other strings (for example, Dr. Smith).