Welcome to Best Practices on Development Workshop’s documentation!

Writing proper documentation will help you and others to understand the code way easier. It will also make you think on your code before actually start coding, just like unit testing!

And with Sphinx, generating this html documentations is done automatically.

Contents:

Source code documentation

Examples module

Module with exercises for the workshop

Examples module API

BestPracticesWorkshop.examples.odd(num)[source]

Return the closest odd number to n

Parameters:n – An integer
Returns:The same integer if it is odd. The next integer otherwise
Return type:int
Raises ValueError:
 If the parameter is not inteer
BestPracticesWorkshop.examples.sum_list(lst)[source]

Sum all elements in list

Parameters:l – List containing elements to sum
Returns:The sum of all elements in the list
Return type:int
Raises ValueError:
 If there is any non-integer element on the list

Indices and tables