Coding style and convention cleanup

- remove training spaces
- remove unused "if __name__ == '__main__'" block
- add newline to the end of file

PEP8 (Style Guide for Python Code)
- limit all lines to a maximum of 79 characters
- don't use spaces around the = sign when used to indicate
  a default parameter value.
- always surround binary operators with a single space on either side
- never use more than one space on both sides of a binary operator

PEP257 (Docstring Conventions):
- use triple double quotes