Jane Street Interview Question

Graph based problem involving non-graph input and basic data structure analysis