Live data from Hacker News

Racket: Lisp for Learning

lwn.net

141–150 of 154 posts

Re: Racket: Lisp for Learning

#141
post #2

Carmack is a huge fan of Racket. He was going to use it as the scripting language for VR until the Oculus execs made him use JavaScript instead (boooooo) https://twitter.com/id_aa_carmack/status/807797812700348416

Last week I tried writing a new Love2d mode for Emacs in Emacs Lisp, but it was on Windows so my muscle memory for Paredit wasn't helpful. Editing s-expressions is a nightmare without some kind of automatic help. Last night I wrote the same plugin for VS Code which used JavaScript, and naturally it was effortless. It got me thinking about how s-expressions are inherently hostile to non-customized setups, whereas Java…

[deleted]

Re: Racket: Lisp for Learning

#142
post #87

Earlier quoted context omitted.

"I can't think of a single feature of ClojureScript that's inherently better than JavaScript" Persistent data structures, multi arity functions, multi methods, transducers, data oriented design, spec, repl driven, better live reloading, meta data, protocols, core async go channels, atoms, Datoms There are breakthroughs in Clojure/Script that literally do not exist in any other language, let alone JS Datomic, Fulcro,…

Persistent data structures: Useful but you can get that in JS too, and if you can get your whole team to agree on it, you can avoid mutable data structures. I've been able to do that 100% for years now. Multi arity functions: That's actually a minus, not a plus. The vast majority of the usages of this are solved with options params with default values in a much clearer way. Multi methods: In 5 years of using Clojure…

Yes, you can do all that in JavaScript using libraries. But in how many of your projects ARE you using all this? That's the question. And what are the steps you have to take and the cognitive load to make sure all the libraries you're using adhere to these conventions, and all the people that contribute code to your project also use the right paradigms?

When all these things are baked into your language, you're free from all the worries and cognitive load to make sure everything works as you expect it to work.

Re: Racket: Lisp for Learning

#143

Earlier quoted context omitted.

Persistent data structures: Useful but you can get that in JS too, and if you can get your whole team to agree on it, you can avoid mutable data structures. I've been able to do that 100% for years now. Multi arity functions: That's actually a minus, not a plus. The vast majority of the usages of this are solved with options params with default values in a much clearer way. Multi methods: In 5 years of using Clojure…

You're rehashing a couple of the most tired arguments Lispers always hear: 1. Parentheses are inconvenient. 2. Everything you can do in Lisp you can do in $other_turing_complete_language. What you're missing in (1) is that as much as you wish you were stating an objective truth of the universe, you're really just stating your own subjective impression. If parentheses were objectively, universally inconvenient, nobody…

> So what's the explanation for that?

Why, they are impractical buffoons who lack the benefit of my own vast personal experience, which trumps everything. Or else blind zealots.

Re: Racket: Lisp for Learning

#144

Earlier quoted context omitted.

Last week I tried writing a new Love2d mode for Emacs in Emacs Lisp, but it was on Windows so my muscle memory for Paredit wasn't helpful. Editing s-expressions is a nightmare without some kind of automatic help. Last night I wrote the same plugin for VS Code which used JavaScript, and naturally it was effortless. It got me thinking about how s-expressions are inherently hostile to non-customized setups, whereas Java…

I've also came upon Clojure after investing much time in Lua/Love2d, but my takeaways are different from yours. I enjoyed Lua's simplicity, portability and execution speed. It shares much of JS strengths, with fewer quirks. I was productive after a weekend of reading Programming in Lua book. Clojure took some more time because I had to unlearn some habits. It's for the best, I think. It's not just about homoiconicity…

> "Clojure took some more time because I had to unlearn some habits. [...] In Clojure it's hard to do the wrong thing, compared to JS or Lua."

I've seen and even written a lot of really really awful Clojure code which technically fits the criteria for good code, on paper, but completely misses the bigger picture. (People have made the same argument for Go, that it's idiot-proof, but I've seen plenty of awful Go code too.) I'm more and more convinced that bad programmers will write bad code in any language and good programmers will write good code in any language.

Re: Racket: Lisp for Learning

#145
post #124

Earlier quoted context omitted.

I had a beautiful beginning with a lisp like programming language when I was 8 or something. Every other languages have been disappointments until I found Clojure a few years ago. I hope you will get it some day.

And I hope you will learn some empathy some day and understand the perspective of others. We all have some growing to do, it seems.

The only way I was able to grok programming was through Racket. I owe my confidence and understanding to Gregor Kizcales’ How to Code, which makes clear to this art student what a dozen other language tutorials in a dozen other languages could not. I deeply love Racket and give thanks to its makers.

Re: Racket: Lisp for Learning

#146
post #2

Carmack is a huge fan of Racket. He was going to use it as the scripting language for VR until the Oculus execs made him use JavaScript instead (boooooo) https://twitter.com/id_aa_carmack/status/807797812700348416

Last week I tried writing a new Love2d mode for Emacs in Emacs Lisp, but it was on Windows so my muscle memory for Paredit wasn't helpful. Editing s-expressions is a nightmare without some kind of automatic help. Last night I wrote the same plugin for VS Code which used JavaScript, and naturally it was effortless. It got me thinking about how s-expressions are inherently hostile to non-customized setups, whereas Java…

Could you share some more information about your Love2d development environement, please?

Re: Racket: Lisp for Learning

#147

Earlier quoted context omitted.

Last week I tried writing a new Love2d mode for Emacs in Emacs Lisp, but it was on Windows so my muscle memory for Paredit wasn't helpful. Editing s-expressions is a nightmare without some kind of automatic help. Last night I wrote the same plugin for VS Code which used JavaScript, and naturally it was effortless. It got me thinking about how s-expressions are inherently hostile to non-customized setups, whereas Java…

I've also came upon Clojure after investing much time in Lua/Love2d, but my takeaways are different from yours. I enjoyed Lua's simplicity, portability and execution speed. It shares much of JS strengths, with fewer quirks. I was productive after a weekend of reading Programming in Lua book. Clojure took some more time because I had to unlearn some habits. It's for the best, I think. It's not just about homoiconicity…

Thanks for making me aware of zprint. Cool that they distribute an AOT compiled binary, too!

BTW, for Sublime, you could install the Terminus package to get an integrated terminal to run clj(1) in. Then with a few lines of Python, you could write a command to send text from the editor side to the REPL side.

(I have a half-baked enhanced Clojure package with some features in this vein, but it's not public atm)

Re: Racket: Lisp for Learning

#148
post #109

Earlier quoted context omitted.

I'm actually glad I read that. I recommend HtDP and Racket semi-regularly because 1) the incidental complexity of getting started with DrRacket is so low and 2) I don't have a better recommendation for a book that covers the same fundamentals. Do you have suggestions to recommend instead?

What kind of context are you looking for? What audience? Is a book the only option? In general, people learn from presentation of material, participation to demonstrate understanding, and then receiving feedback. They need to be motivated and engaged. If you're asking how I would suggest someone self-learn something, I would suggest that they find a cool project that they're excited by, and then offer resources based…

I typically recommend it for someone entirely new to programming. I don't know where else to point them for something that gets down to the meat of conditionals, repetition, and functions and applying them to data structures with as little distraction.

A book isn't the only option, certainly.

Re: Racket: Lisp for Learning

#149
post #146

Earlier quoted context omitted.

Last week I tried writing a new Love2d mode for Emacs in Emacs Lisp, but it was on Windows so my muscle memory for Paredit wasn't helpful. Editing s-expressions is a nightmare without some kind of automatic help. Last night I wrote the same plugin for VS Code which used JavaScript, and naturally it was effortless. It got me thinking about how s-expressions are inherently hostile to non-customized setups, whereas Java…

Could you share some more information about your Love2d development environement, please?

Sure, I'll write a blog post about it next week and post it on https://sdegutis.github.io, check back there in a week.

Re: Racket: Lisp for Learning

#150

Earlier quoted context omitted.

Last week I tried writing a new Love2d mode for Emacs in Emacs Lisp, but it was on Windows so my muscle memory for Paredit wasn't helpful. Editing s-expressions is a nightmare without some kind of automatic help. Last night I wrote the same plugin for VS Code which used JavaScript, and naturally it was effortless. It got me thinking about how s-expressions are inherently hostile to non-customized setups, whereas Java…

I've also came upon Clojure after investing much time in Lua/Love2d, but my takeaways are different from yours. I enjoyed Lua's simplicity, portability and execution speed. It shares much of JS strengths, with fewer quirks. I was productive after a weekend of reading Programming in Lua book. Clojure took some more time because I had to unlearn some habits. It's for the best, I think. It's not just about homoiconicity…

Have you seen/tried fennel[1] or Urn[2] ?

[1] https://github.com/bakpakin/Fennel

[2] https://urn-lang.com/

Post reply on HN