Synchrony Interview Question

Dealing with responses from api in python