Solution for the third lab at "Scripting Languages" course - Python