python doc code example
Example 1: python function docstring
def functionName():
"""
This is a function docstring
"""
Example 2: docstrings in python
# Docstrings are used create your own Documentation for a function or for a class
# we are going to write a function that akes a name and returns it as a title.
def titled_name(name):
# the following sting is Docstring
"""This function takes name and returns it in a title case or in other
words it will make every first letter of a word Capitalized"""
return f"{name}".title()
Example 3: python documentation
dont read documentation until you understand the core concepts of Python!
Example 4: latest version of python
# For macs...
# Apparently you don't want to upgrade 2.* just install 3.*
% brew install python3