names = ['Alice', 'Bob', 'Dilbert']
Use:>>> names = [
... 'Alice',
... 'Bob',
... 'Dilbert',
... ]
That way there’s one item per line, making it perfectly clear which one was added, removed, or modified when you view a diff in your source control system. It’s a small change but helpful to avoid silly mistakes. It also easier for your teammates to review your code changes.#Source "Python Tricks" by Dan Bader