Added part 3b with python script