Use a more pythonic approach
Improve code documentation and variables naming