final version of 4th python task