News for hackers. Stuff that matters.
Re:First Impressions of Python from a Java Developer by whakojacko on Monday November 08, 2010 @04:10PM (#1884021)
You can do similar in scala, either

  val allowed_usernames = all_users.filter(_.is_admin()).map(_.username)
or

  val allowed_usernames = for(user <- all_users if user.is_admin()) { yield user.username }
And still get all the of goodness of Trivial jvm/java compatability...
Re:First Impressions of Python from a Java Developer by jcromartie on Monday November 08, 2010 @05:15PM (#1884261)
Or Clojure... (or... or... or...)

    (map :username (filter admin? all-users))
Re:First Impressions of Python from a Java Developer by Scriptor on Monday November 08, 2010 @06:19PM (#1884477)
Or Clojure again

    (for [username all-users] :when (admin? username))
Re:First Impressions of Python from a Java Developer by moshezadka on Monday November 08, 2010 @05:11PM (#1884246)
Nothing against scala, but you can program in Python and get all the goodness of JVM compat by simply running your programs in Jython...
Re:First Impressions of Python from a Java Developer by lusis on Tuesday November 09, 2010 @01:20AM (#1885585)
Jython is behind current python implementations. If you're comfortable with being compatible up to python 2.5 then go right ahead. But if you need 2.6 or 2.7 compatibility, Jython is sadly not an option.