Bloomberg Interview Question

Flatten a linked list, the listnode has a down pointer and right pointer. We always flatten the down node first, then the right node.