Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

In this very specific instance, you could easily and idiomatically reuse a single instance of an immutable empty list:

https://docs.oracle.com/javase/7/docs/api/java/util/Collecti...

No dynamic heap allocation necessary.



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

Search: