python learning test code