3. Personally, I don't like names formed like this x->y to indicate a conversion because this order makes it difficult to understand compositions; for example, ( y->z(x->y... ) ) is less straightforward than (z<-y(y<-x... ) ). In contrast, x->y is much easier to read than y<-x. You can see here one of the many difficulties that language designers come up against.
What kind of retoid do you have to be to not be able to parse (y->z (x->y X)) naturally. Might as well complain about (> a b)
Name:
Anonymous2013-06-15 11:18
so instead of (f x) use reversed notation (x f) and then ((.. x->y) y->z) is easy to read
Name:
Anonymous2013-06-15 14:44
Common Lisp is not functional language
in fact this is first version of perl without syntax
but with macroses
Name:
Anonymous2013-06-15 19:06
Going to do (y->z (x->y x)) a lot in your code?
(define (x->z x) (y->z (x->y x)))
And BAM, you can now do (x->z x).
It's like magic, eh? Who would've thought that defining new functions makes it easier to do repetitive operations that are otherwise awkward and/or long-winded to express in the language? It's almost as if they were precisely meant for this!
Then there's also the fact that in Scheme and Lisp in general, you can not only define new functions, but also new syntax, but I better don't blow your minds out with that.
Name:
Anonymous2013-06-16 3:26
What are abstractions with procedures?
Read your FUQIN SICP, OP.
Name:
Anonymous2013-06-16 3:33
no, op is right. message passing syntax is more intuitive in every way.
(y->z (x->y x))
x :x->y :y->z
x.toY().toZ()
Name:
Anonymous2013-06-16 5:22
>>6
that doesn't help, Now I'm just going to do (define (x->zx) (y->z (x->yx))) a lot (for varying x,y,z)