Live data from Hacker News

Why Racket? Why Lisp? (2014)

practicaltypography.com

161–168 of 168 posts

Re: Why Racket? Why Lisp? (2014)

#161

It's about a month since I've started seriously diving into lisp. The last couple of weeks I've spent my days reading 'The joy of Clojure', Structure and Interpretation of Computer programs, lots of tutorials and documentation, playing around in the repl + experimenting with all kinds of frameworks and libs in clojure (eg. Om). I've spent today implementing the brainfuck interpreter in Racket. I can't explain it, it'…

I had this experience, too, years ago. I felt like my brain was getting rewired. I loved it. I also noticed that I was thinking in Lisp relatively quickly. To this day when I have a really hard problem I want to solve I write the code in Lisp because it makes hard things easier to understand. Then I implement it in the language I'm using.

You begin thinking "naturally" in Lisp because there's no syntax to memorize, it's all data and / or semantics. You can literally write the code in your head. Languages I've used for years and years don't do this to me like Lisp does.

It also made me feel more confident about programming in other languages and not to get distracted by "fancy" syntax or features that are just warmed over scraps from the floor of Lisp's feast on the table.

Re: Why Racket? Why Lisp? (2014)

#162

Has anyone tried to use Butterick's Pollen and written about it? The idea of debugging your website with racket as you write markup and styles seemed really interesting alternative to what I do; write styles, refresh, and then refine the stylesheet by incrementally adding changes with the inspector and then copying them to my stylesheet.

I'm working on converting a fiction ebook to web-based with Pollen and may later launch a fiction magazine using it, although I'm undecided about that technology choice. I think Pollen's biggest strength is that you can reprogram its markup -- as its documentation puts it, you can attach behavior to tags. I haven't taken much advantage of that yet, but you can do things like create a "TOC" tag that builds a table of…

FWIW I go between DrRacket and Sublime Text as necessary. Sublime is of course faster for typical writing & editing tasks. But when working on code-related things, the DrRacket REPL is useful.

Re: Why Racket? Why Lisp? (2014)

#163

Earlier quoted context omitted.

I'm working on converting a fiction ebook to web-based with Pollen and may later launch a fiction magazine using it, although I'm undecided about that technology choice. I think Pollen's biggest strength is that you can reprogram its markup -- as its documentation puts it, you can attach behavior to tags. I haven't taken much advantage of that yet, but you can do things like create a "TOC" tag that builds a table of…

FWIW I go between DrRacket and Sublime Text as necessary. Sublime is of course faster for typical writing & editing tasks. But when working on code-related things, the DrRacket REPL is useful.

That makes sense. I think I was using Sublime as well -- I experimented with making the world's hackiest syntax highlighting file to show embedded Pollen commands. (IIRC, Sublime was unamused with the notion of ".html.pmd" as a single extension.)

Re: Why Racket? Why Lisp? (2014)

#164

Earlier quoted context omitted.

I'm working on converting a fiction ebook to web-based with Pollen and may later launch a fiction magazine using it, although I'm undecided about that technology choice. I think Pollen's biggest strength is that you can reprogram its markup -- as its documentation puts it, you can attach behavior to tags. I haven't taken much advantage of that yet, but you can do things like create a "TOC" tag that builds a table of…

Thanks for the response. I might try converting some public domain text to Pollen sometime, any tips for getting around DrRacket's short comings besides separating racket and pollen source?

That's probably the main one, really. DrRacket really isn't a bad IDE -- it's not up to Emacs levels of programmable madness, but its keybindings are clearly inspired by Emacs and it has a lot of Lisp-aware functionality. But, its syntax highlighting engine seems to be very slow and hard to really turn off.

If you are an Emacs fan, you can use it for Racket instead of DrRacket using Geiser and Quack, which might solve a lot of problems. (I've never tried it -- I'm comfortable with Emacs, but I've never loved the way it handles prose rather than code.)

Re: Why Racket? Why Lisp? (2014)

#165

Earlier quoted context omitted.

Hash tables have nothing to do with imperative programming. It's just a coincidence that some MLs or Schemes don't include purely functional hash tables; Clojure and Racket both include have them.

This is wrong. There are no purely functional data structures analogous to hash tables in terms of performance. Hash tables are inherently stateful and cannot be implemented without state.

Most people are OK taking a small performance hit for the simplicity of working with immutable data.

Re: Why Racket? Why Lisp? (2014)

#166
post #98

Don't waste your time with lisp. Learn lambda calculus and then see how these ideas are applied in actually useful imperative programming languages.

Pretty ironic you've been posting here for 4 years to a site built with a language that's not useful.

I'll believe that it's useful when unenlightened plebs like me start getting money thrown at them for writing lisp code. So far the industry seems to disagree with you about what's useful.

Re: Why Racket? Why Lisp? (2014)

#167
post #98

Don't waste your time with lisp. Learn lambda calculus and then see how these ideas are applied in actually useful imperative programming languages.

Pretty ironic you've been posting here for 4 years to a site built with a language that's not useful.

This site's backend could be built with dozens of different languages.

Re: Why Racket? Why Lisp? (2014)

#168

Earlier quoted context omitted.

PCL is a good book but too wordy for my taste. Paul Graham's ANSI Common Lisp will get an advanced programmer up to an advanced level more quickly and efficiently. http://www.paulgraham.com/acl.html

I'd say both are essential, but PCL should be digested first (no need to read every paragraph). On Lisp is IMHO a lambda power user guide and not a good general introduction to CL.

Note that I recommended the book "ANSI Common Lisp" for an advanced (non Lisp) programmer, not "On Lisp".

That aside, I agree with your description of On Lisp.

Post reply on HN