Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

Common Lisp is too hard.

Name: Anonymous 2007-12-04 19:06

I still can't get my head around prefix notation. I heard Scheme is easier though. Seriously, why do practitioners of Lisp-like languages claim it's so good? I honestly cannot see the big deal, it's an old, slow, awkward and overall clunky language to use.

Name: Anonymous 2007-12-05 14:26

lol holy shit you fucking faggots

If you just learned lisp yesterday (or you're slow and you've been learning it for 10 years but still think it's the best thing in the world), infix arithmetic is better!
Simply fucking is you idiot.

The reason prefix notation is better is because you have a single uniform representation of code and [u]data[/d], the language is homoiconic.

(= CODE DATA) ;; BITCH DO YOU UNDERSTAND??

something like 2 + 4*x is BETTER than (+ 2 (* 4 x)), ALSO 2 + (4*x) is just TOTALLY STUPID LEARN TO CONTEXT FREE PARSE IN YOUR HEAD!!!!

Look I doubt any of this is getting through to the smug lisp newbies and the C faggots (even more inexperienced than smug lisp newbies) but as a summary:

* Every language (ignoring shit ones) is different and will stretch your mind and let you program in a new way
* Lisp has prefix notation and s-expression because this works beautifully with homoiconicity, macros etc
* Infix arithmetic is more readable, easier to manipulate algebraically so it IS simply better -- this does not detract from the beauty and elegance of Lisp
* THERE IS NO LANGUAGE WAR/CONTEST, IF YOU DONT KNOW HOW TO PROGRAM WELL IN EVERY SINGLE LANGUAGE YOU FAILED ARUGING ABOUT PROGARMMING LANGUAGE CHOICE IS FOR CHILDREN AND REDDIT USERS.

.... I think that I had a point..... didn't I?

Name: Anonymous 2007-12-05 14:56

The reason prefix notation is better is because you have a single uniform representation of code and [u]data[/d], the language is homoiconic.

If you mean the fact that in Lisp everything is a car, a cudder, or a paren (a list generally), then yes, I agree. The car of any SEXP is the operator; the cudder are the arguments. This way, you can clearly see the operator of any expression. The prefix notation also makes the INDENTATION prettier.

Name: Anonymous 2007-12-05 14:57

>>42
[u][b]DICKS[/u][/b]

Name: Anonymous 2007-12-05 14:58

I meant DICKS.

Name: Anonymous 2007-12-05 16:56

>>41
Nothing in your post made any sense whatsoever.

And you also fail at BBCode.

An hero tiem.

Name: Anonymous 2007-12-05 16:59

>>41
The reason fucking men in the ass is better than fucking women is because you have a single uniform representation of gender, the fucking is homosexual.

(= PENIS ASS) ;; BITCH DO YOU UNDERSTAND?

I DO NOT NEED TO EXPLAIN THIS ANY FURTHER, THE TERM HOMOSEXUAL SHOULD BE PROOF ENOUGH.

Name: Anonymous 2007-12-05 17:00

>>41
The reason prefix notation is better is because
...it's easier to parse. Especially back then when LISP was still remotely relevant. Zing!

Name: Anonymous 2007-12-05 17:03

>>47
Back then?  They didn't have Haskell back then, how could they have parsed Lisp?

Name: Anonymous 2007-12-05 17:12

protip:
it's (+ a b) because '+' is a function

Name: Anonymous 2007-12-05 17:49

>>48
It is a mystery.

PS: Haskell reeks.

Name: Anonymous 2007-12-05 17:54

HMM

Name: Anonymous 2007-12-05 17:55

TESTING

Name: Anonymous 2007-12-05 17:55

Last test

Name: Anonymous 2007-12-05 18:07

4.*(73.*(5.+(10.+(8.-(8)))))

Valid Ruby

Name: Anonymous 2007-12-05 18:14

int a = 4 * (73 + 5);
As opposed to
(setf a (funcall #'* 4 (+ 73 5)))
Tell me which one is easier to read (HINT: it's not the latter)

Name: Anonymous 2007-12-05 18:17

Oops slight error in the CL:

(setf a (funcall #'* 4 (funcall #'+ 73 5)))

Name: Anonymous 2007-12-05 18:26

>>55
and why setf? maybe a simple (with) would be ok. something like

(with var a = (* 4 (+ 73 5)) in ...)

Name: Anonymous 2007-12-05 18:28

>>57
No, you cannot use with, this is outside the problem domain.

Name: Anonymous 2007-12-05 18:33

>>57
What the fuck is (with)?

Name: Anonymous 2007-12-05 18:35

>>56
Don't you mean (setf a (apply #'* (list 4 (apply #'+ (list 73 5)))))?

Name: Anonymous 2007-12-05 18:47

>>59
It's a macro which allows you to make closures.

Name: Anonymous 2007-12-05 18:52

>>61
But why do you guys keep talking about it like it's standard?

Name: Anonymous 2007-12-05 19:05

Because it's in the CL ansi standard.

Name: Anonymous 2007-12-05 19:43

>>62
it's not standard, then again neither is (iter), yet everybody uses it. It's a general binding macro, includes let, multiple-value-bind, and stuff.

Name: Anonymous 2007-12-05 19:50

>>64
Iterate I know, but I've never seen with mentioned outside /prog/.

Name: Anonymous 2007-12-05 19:59

>>63
l2hyperspec

Name: Anonymous 2007-12-05 20:30

>>65
maybe I'm the only one here who uses with, so you everytime you see it here it's because i'm using it.

Name: Anonymous 2007-12-05 21:57

>>67
I think that's very likely.

Name: Anonymous 2007-12-05 22:07

>>68
yes.
but i'm not >>59. then again it's not a macro to create closures.

Name: Anonymous 2007-12-05 22:28

>>14
wow, what a fail language.
here's fizzbuzz in a much cleaner language:
: d dupd mod zero? ;
100
[
 1+ 15 d [ drop "FizzBuzz" ]
 [
  3 d [ drop "Fizz" ]
  [
   5 d [ drop "Buzz" ] when
  ] if
 ] if .
] each

Name: Anonymous 2007-12-05 23:04

>>70
That CL version is maybe more verbose than necessary.

Name: Anonymous 2007-12-05 23:10

>>71
all CL is more verbose than necessary.

Name: Anonymous 2007-12-05 23:38

>>72
All CL is exactly as verbose as necessary.

Name: Anonymous 2007-12-05 23:44

>>73
x g f >>> [code](f (g x))[code]

Name: Anonymous 2007-12-06 0:07

>>74
Your first example is insufficiently verbose.

Name: Anonymous 2007-12-06 0:33

(loop for i from 1 to 100                                             
      do (cond ((= 0 (mod i 15)) (format t "FizzBuzz~%"))              
               ((= 0 (mod i 3))  (format t "Fizz "))                   
               ((= 0 (mod i 5))  (format t "Buzz "))                   
               (t                (format t "~a " i))))

Name: Anonymous 2007-12-06 0:48

>>76
Forgetting some newlines there?

Name: Anonymous 2007-12-06 1:01

>>76
I didn't think it was possible for anyone to fail FizzBuzz. Obviously, I was horribly mistaken.

Name: Anonymous 2007-12-06 1:10

>>75
how so?

Name: Anonymous 2007-12-06 1:16

That lisp crap isn't taught in my skool. Best decision they ever made.

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List