PyDocs and PEP8

PyDocs

PyDocs is shorthand for Python Documentation and will be your go-to resource for everything Python. It is highly encouraged that you attempt to find the answer using PyDocs before asking an instructor or anyone else a question. Understanding how to use PyDocs is not only testable... but it's an essential piece in becoming proficient in Python.

2.7: https://docs.python.org/2/index.html

3.x: https://docs.python.org/3.6/index.html

Standard Libary

The Python Standard Library contains all of the built in functionality of Python; and well, theres a lot of content in there. The lectures will not even begin to scratch the surface of the Standard Library. With that said, you are encouraged to dive into the library and use whatever you can... whenever you can. You are not limited to just what I teach you. USE THE LIBRARY!

2.7: https://docs.python.org/2.7/library/index.html

3.x: https://docs.python.org/3/library/index.html

Styling and PEP8

PEP8 is shorthand for Python Enhancement Protocol 8. Think of this as the bible for Python; the dos and do-nots of formatting and styling. Below are some of the more important commandments.

  • Python is whitespace sensitive! Unlike C, C++, Java, etc, Python does not use brackets. Instead, Python utilizes an indentation system.
  • Spaces is preferred over tabs, you cannot mix. PEP8 commands 4 spaces per indention level (tab). Using editors with different tab settings may break code!
  • To ensure you do not break your code... use spaces! (You can setup the tab button to input 4 spaces on most major text editors and IDEs)
  • Documenting Code:
# This is a comment
"""This is a single line docstring"""
"""This is a 
multiline comment"""

PEP8: https://www.python.org/dev/peps/pep-0008/

results matching ""

    No results matching ""