finished A4
updated to python 3