Domanda di colloquio di Autodesk

Two-sum question in Python, and the time complexity.