Mainly code formatting changes

- PEP08 compatible
- Spaces, not tabs
- JSLint compatible
- PyFlakses compatible
- Grammar
- Removing comments
- Unifying double- and single-quotes
- Use of anonymous functions
- Python list identity preserved ([:] = [])