ASPN ActiveState Programmer Network
ActiveState
/ Home / Perl / PHP / Python / Tcl / XSLT /
/ Safari / My ASPN /
Cookbooks | Documentation | Mailing Lists | Modules | News Feeds | Products | User Groups


Recent Messages
List Archives
About the List
List Leaders
Subscription Options

View Subscriptions
Help

View by Topic
ActiveState
.NET Framework
Open Source
Perl
PHP
Python
Tcl
Web Services
XML & XSLT

View by Category
Database
General
SOAP
System Administration
Tools
User Interfaces
Web Programming
XML Programming


MyASPN >> Mail Archive >> ruby-talk
ruby-talk
Re: "Real" Differences Between Python & Ruby
by Michael T. Richter other posts by this author
May 9 2008 10:43PM messages near this date
Re: "Real" Differences Between Python & Ruby | Re: "Real" Differences Between Python & Ruby
On Sat, 2008-05-10 at 02:13 +0900, Max Cantor wrote:

>  Maybe a different spin on my question could be, "What
>  problems did Ruby solve, as a new language?"


I'm not sure that this is a meaningful question.  What problems did any
language past patch cabling circuit boards solve?  If you set the bar
low enough (or high enough) all current computer languages are imperfect
reflections of a Turing machine anyway.  (Yes, even the functional ones
based on Church instead of Turing.  They're just REALLY obfuscated.)

As a former intensive Python evangelist (to the dread of my coworkers at
the time) and a now very happy Ruby user (despite Ruby's many quirks --
and yes, I'm using the term here in its negative connotation) what I see
Ruby bringing to the table that made me switch is:

     1. A more flexible syntax which, while harder to learn completely,
        makes things easier to read when I have learned it.  As a
        trivial example there's no need for if...elsif...else...end,
        unless...else...end, ...unless..., ...if..., ...?...:...,
        case...when...else...end and all other such conditionals.  They
        can all be handled with if ... else ... end and nothing more.
        Yet the expressiveness of the language increases when I can pick
        and choose the construct that most accurately and succinctly
        expresses my intent.
     2. Just enough support for functional-style programming that I
        don't feel like I'm fighting the language each step of the way
        when I'm trying to accomplish things I'm used to doing now.  (If
        Ruby could add zero-stack tail recursion to its bag of tricks
        I'd be really happy!)  Python has some support for the
        functional style, but Guido is noted as not thinking that it's
        important to support and, I think, secretly puts barriers to
        proper functional programming in place because he doesn't like
        it.
     3. A far friendlier community.  This is not a technical reason to
        switch, but given the complexity of modern programming languages
        and the even greater complexity of the bewildering variety of
        libraries available a decent community is vital for a language.
        I would far rather use a "substandard" language with a great
        community than a great language with a snotty, unhelpful
        community.  I grew disgusted -- utterly disgusted -- with the
        Python community about eight years ago and have never bothered
        to poke my nose into the mailing lists, etc. since except for a
        few instances where I held my nose, asked my question, filtered
        through the hostile noise and found the answer.  If I got an
        answer at all.  The Ruby community is far more prone to good
        answers without the smart-ass syndrome -- although this is
        lamentably on the rise -- and far more welcoming to newcomers --
        although this is lamentably on a decline.  (Don't even get me
        started on the Common Lisp community of c. a decade ago.  Just
        Google for "Erik Naggum" for a representative example.)
     4. No syntactic whitespace.  While I initially liked and defended
        the indentation scheme of Python, it was because I only ever
        wrote my own scripts for my own purposes.  As soon as I had to
        work with another person using Python the weakness became
        evident.


-- 
Michael T. Richter <ttmrichter@[...].com>  (GoogleTalk:
ttmrichter@gmail.com)
It's OK to figure out murder mysteries, but you shouldn't need to figure
out code. You should be able to read it. (Steve McConnell)
Thread:
Max Cantor
Avdi Grimm
Globalrev
Marc Heiler
Max Cantor
Michael T. Richter
M. Edward Borasky
Michael T. Richter
M. Edward Borasky
Eleanor McHugh
Michael T. Richter
Steven Parkes
Avdi Grimm
Max Cantor
Adam Shelly
Robert Dober
David A. Black
Robert Dober
Phillip Gawlowski
Martin DeMello

Privacy Policy | Email Opt-out | Feedback | Syndication
© 2004 ActiveState, a division of Sophos All rights reserved