Whenever you're ready, walk me through how you'd approach this.
Explain the time and space complexity of the solutions you provide.