Python vs. Perl, which is better to learn?
Ian Bicking
ianb at colorstudy.com
Fri May 3 15:56:25 EDT 2002
On Fri, 2002-05-03 at 11:02, Alex Martelli wrote:
> Actually, it's when a callable HAS arguments that it may be least
> disruptive to allow it to be called without parentheses, just by
> "juxtaposition" to its arguments. I do admit I love Haskell's
> way of expressing "f a b c", so clean -- no noisy parentheses nor
> commas for the typical case. Of course, it DOES require the
> "implicit currying" concept, so that e.g. f a may return a function
> that then takes b and returns a function that ... -- delightful,
> but perhaps not all that applicable unless the compiler has some
> strong information about what callable takes what arguments:-).
FYI, Logo also does this, in an interpreted form. Similar in semantics
to Tcl, it only parses code at the time it is run (truly interpreted,
unlike Python -- though this may not be a feature :). E.g.:
to add :a :b
output :a + :b
end
fd add 1 2 rt 90
; Parsed as (fd (add 1 2)) (rt 90)
No one really pays attention to Logo now, or maybe ever, but it's really
a more elegant language than one would expect. In it's domain I think
it still has a lot to offer in terms of usability. But then programming
languages targeted at the semi-literate with poor keyboarding skills
have never done that well. Though that might make some people think of
some other choice languages :)
Ian
More information about the Python-list
mailing list