Live data from Hacker News

Structure and Interpretation of Computer Programs – JavaScript Adaptation

sicp.comp.nus.edu.sg

151–160 of 188 posts

Re: Structure and Interpretation of Computer Programs – JavaScript Adaptation

#151
post #78

Earlier quoted context omitted.

> JS is a great language literally no one believes this

I like JS. I use JS daily. JS is part of the workflow for nearly everyone I know who works with code. For me, ES6 is fantastic to use. Some of the better books on JS [I'm thinking specifically of Haverbeke's "Eloquent Javascript"] are general computing classics in their own right. I used to be a snob about JS, due to the fact that in the 90s / early 2000s, it had major shortcomings and produced a lot of slow, crashy…

Here's a link to that book you mentioned if anyone needs it: https://eloquentjavascript.net/Eloquent_JavaScript.pdf

Thanks, I'm reading it now.

Re: Structure and Interpretation of Computer Programs – JavaScript Adaptation

#152
post #49

Every now and then a great movie comes out. Then it gets its American remake. It's been proven you can put Al Pacino, Robert de Niro and Bruce Willis in any movie (with predictable results!). This is the book equivalent of an American remake for me. Is Javascript the new pseudocode? Honestly I'd rather be forced to learn a new language to understand a book than to read the book adapted to JS.

Well since I very much enjoy the first half of SICP I like that I can look at problems I have some familiarity with in a language I use day to day.

Anyway, how did you like the Pacino remake of Pippi Longstocking?

Re: Structure and Interpretation of Computer Programs – JavaScript Adaptation

#153
post #150

Earlier quoted context omitted.

JS is a terrible language. The amount of pitfalls, language features you must avoid, and obscure paradigms you must follow to make JS usable is mind-boggling. Just because you can use JS well doesn't mean it's a good language.

Out of curiosity, what languages do you think are good ones?

Good? That's harder to answer. Not terrible? Java, C, Python, C#, Swift, Go...

Re: Structure and Interpretation of Computer Programs – JavaScript Adaptation

#154
post #78

Earlier quoted context omitted.

Typical dramatic Hacker News user. JS is a great language and enjoyed by millions of developers.

> JS is a great language literally no one believes this

Literally Douglas Crockford made a second career out of believing this.

Re: Structure and Interpretation of Computer Programs – JavaScript Adaptation

#155

Earlier quoted context omitted.

But WebAssembly was just made a new standard by W3, which, correct me if I'm wrong, will allow browsers to natively support literally any other language the developers choose.

Yes, but only if those languages do not interact with the platform (the platform being "webpages"). DOM manipulation requires JavaScript. So, it is still the case that JavaScript is the only language with first class support.

Afaik when I write react , 100% of real(!) dom manipulation is already abstracted away. So why wouldn’t that work with webAsm?

Re: Structure and Interpretation of Computer Programs – JavaScript Adaptation

#156
post #78

Earlier quoted context omitted.

> JS is a great language literally no one believes this

I love ES5. The language has gone downhill though.

Now thats an unusual viewpoint? Could you elaborate why you think so?

I personally found js terrible before es6 and love it since then

Re: Structure and Interpretation of Computer Programs – JavaScript Adaptation

#157

Earlier quoted context omitted.

Typical dramatic Hacker News user. JS is a great language and enjoyed by millions of developers.

Yes, it's such a great language that `{} + []` is a valid program.

Every read about the crazy things you can do with C?

Re: Structure and Interpretation of Computer Programs – JavaScript Adaptation

#158
post #97

Earlier quoted context omitted.

Few people do that outside of code obfuscation contests, but the point is JS has heaps of gotchas like that, each waiting to bite you. How about: x = 5; (no var declaration). Extremely easy to do by accident. Lots of these will be left for backwards compatibility. In JS errors often go silent and I developed a strong dislike for any language that does that, including Vimscript and Lua (and I do like Vim).

No JS developer would do that. We all know that is global. Nowadays you use `const` or `let`. Any JS developer will have a linter that will tell them incase they somehow made that mistake.

That's all fine, but those are all workarounds for a design mistake in the language.
Post reply on HN