Frage im Vorstellungsgespräch bei CIBC

Coding interview regarding optimization and space complexity.