Skip to content

Latest commit

 

History

History

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 

README.md

Code Conventions


This helps everyone to read and maintain the code even when they are maintains someone else code
Please restrict to the rules.

Rules:

  • A line must not exceed 80 character length.
  • Use Spaces not Tabs.
  • Always return to example_google.py file.
    • We dissagree with example_goole.py in variables naming ONLY,
      and we agree with it in the whole entire rest.

Naming:

  • Class Name: PascalCase: initial letter is upper case
    • Examples: Class, NewClass, ...
  • Function: snake_case: Lowercase underscore-separated names.
    • Examples: foo, foo_name, ...
  • Variables: lowerCamelCase: initial letter is lower case and rest are PascalCasee.
    • Examples: variable, varibaleName, ...

Function prototypes

  • Functions should have a description followed by sections as in the following example.
  • You don't need to include all section, but include what makes the function as clear as possible.
  • Function prototypes also used for proposed functions.
def function_with_types_in_docstring(param1, param2):
    """Here you write a  rigorous description of the function
    
    Args:
        param1 (int): The first parameter.
        param2 (str): The second parameter.
        
    Returns:
        bool: The return value. True for success, False otherwise.
        
    Note:
        Do not include the `self` parameter in the ``Args`` section.

    """
    pass # in case it is just a prototype (not implemented yet)