Efficient recursive iteration over self referencing struct

Interesting, i’m know about Data Structures, but i’m still noob when it comes to choose which one is better for the job.

Yes, i’m familiar.