Hacker News new | past | comments | ask | show | jobs | submit login

You usually solve this by using a traversal helper that keeps the stack and next/prev for you without storing them inside the AST explicitly.



Consider applying for YC's Summer 2025 batch! Applications are open till May 13

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: