William James schrieb:Kenny was right #JusticeForKenny
On Sep 12, 6:51 am, p...@informatimago.com (Pascal J. Bourguignon)
wrote:
William James <w_a_x_...@yahoo.com> writes:
Ruby:If you want to keep writing Ruby in cll,
I don't want to, but I feel that it is important
to make the superiority of COMOL-LISP glaringly
evident to all window-shoppers who read this group.
This will be done simply by showing that Ruby code
is always more prolix, more convoluted, less elegant,
and less readable to a normal human than CLISP code.
Admittedly, my attempts so far have been ratherTo be successful you should show algorithms to solve the problem
unsuccessful. I hope to improve with practice.
which can’t be expressed with the same ease in Lisp.
In all of your examples you only made use of facilities which Ruby
got from Lisp (like loops, blocks, injects, ...). Of course this can
not impress anyone here, because all this stuff already is in Lisp.
A Haskell fan can at least bring in implicit currying and pattern
matching. This can of course also be done in Lisp, but at least such
attempts make much more sense, because these techniques can indeed
reduce program complexity.
By saving three keystrokes with Rubys map vs Lisps mapcar no piece
of software becomes easier to understand (nor can it be written faster
in any meaningful way).
As long you show only some functions calls, a bit imperative style here
some funky functional style there you won’t be able to beat Lisp, as it
can be done the same way. Bring in abstractions. Look at Haskell or
Prolog or Mercury. They offer abstractions which are not always so
very easy to implement in Lisp.
André
--
(defun tv (x)
(if (consp x)
(loop for y in x do (tv y))
(format t "~a " x)))
Sysop: | Keyop |
---|---|
Location: | Huddersfield, West Yorkshire, UK |
Users: | 403 |
Nodes: | 16 (2 / 14) |
Uptime: | 43:31:48 |
Calls: | 8,407 |
Calls today: | 2 |
Files: | 13,171 |
Messages: | 5,905,025 |