Shared publicly  - 
New Blog Post: Examining, Comparing & Contrasting Mutable State, If/Else Blocks & For Loops in Java, Python, and Scala.
Brandon Hudgeons's profile photoMarc-Daniel Ortega's profile photoChristopher Taylor's profile photo
Nice post . Enjoyed it. I read too fast J. Suereth book and forgot about the @switch.
thanks for the interesting post, I didn't know about @switch either. As a commenter on the blog noted, using the collections part of google's guava libs can ease a lot of the pain. Since the static methods in Iterables ( -- esp. transform and filter) produce lazy results, they even act a bit like generators in python. Obviously the syntax is nowhere near as nice, but if you create a bunch of factory methods for the Predicates and Functions, you can get pretty decent code.
Add a comment...