Flexport interview question

Problem solving question about data structures.