Hacker News new | ask | show | jobs
by qw 1702 days ago
I know it's probably to late to add any value to the discussion, but you can write this in Java;

    var list = List.of("carrot", "fox", "explorer")
You are right about the builder, but most projects I have worked with use Lombok and the @Builder annotation to generate the builder automatically. I agree that a native syntax for this would be better.