I had a technical phone screen with one of the software engineers. For the first 10 minutes, he introduced himself and I gave an introduction about myself. The following question was asked to code on coderpad.
you have list of date ranges (start and submit times) representing start/submit times of loan applications.
All times are positive 64-bit integer timestamps, and the ranges are inclusive on left and exclusive on right.
The goal is to generate a time series (list of time and count, sorted by time) of the number of active loans over time.
input: array of maps from string to int64
[
{"start": 1, "end": 9},
{"start": 3, "end": 10},
{"start": 2, "end": 6},
{"start": 7, "end": 9999999999}
]
output: format up to you - goal is to print to console
1: 1
2: 2
3: 3
6: 2
7: 3
9: 2
10: 1
9999999999: 0He asked me the complexity of the code and scalability of the code. Last 5 minutes was reserved for questions.