Live data from Hacker News

Structure and Interpretation of Computer Programs – JavaScript Adaptation

sicp.comp.nus.edu.sg

111–120 of 188 posts

Re: Structure and Interpretation of Computer Programs – JavaScript Adaptation

#111

Earlier quoted context omitted.

What an extremely weak criticism that has been played out. 1) Don't concatenate them in the first place 2) Use TypeScript Pro-tip, if the world is going JS and you don't get it, it's probably you. With JS (TypeScript) I can develop on every platform natively (React Native). I can compile to native code. (AssemblyScript). I'm not saying you can't do those things on other languages, but JS is becoming a powerhouse than…

Javascript is such a good language that, even after two decades of fixes, it's only good when you use a different language - specifically created to address JS's many problems - that compiles to it.

TypeScript is JavaScript. They follow and contribute to the Ecmascript spec.

It pretty much just strips the typing out when "compiling".

All the JS problems have been solved in ES6+

There are many languages that have supersets.

Re: Structure and Interpretation of Computer Programs – JavaScript Adaptation

#113
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

JavaScript may have its quirks, but TypeScript is a great improvement. And with a few tweaks to your package.json, you can code in TS for Node.js!

Re: Structure and Interpretation of Computer Programs – JavaScript Adaptation

#114
post #97

Earlier quoted context omitted.

Do you find yourself accidentally doing that often? A few of the things from the "Wat" video fall into that category. "Things no one would have ever thought to try, yet a dynamic language will fully allow". If you want to point out valid concerns with JS, the double-equal implicit coercion is a far more frightening "gotcha".

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.

Re: Structure and Interpretation of Computer Programs – JavaScript Adaptation

#115
post #87

Earlier quoted context omitted.

If learning a new language and syntax is a barrier, you will not be able to follow SICP anyway, since it includes developing multiple languages in various paradigms.

Oh, okay. I thought I was just lazy, not dumb. My bad.

Come on, I'm not putting anybody down. Just pointing out that you cannot avoid learning new languages anyway, since the exercises in the book requires you to design multiple different languages. It is basically a book about language design.

Re: Structure and Interpretation of Computer Programs – JavaScript Adaptation

#116
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.

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

Agreed. I'm pretty sick of the anti-JS kneejerk rhetoric that happens here.

It adds zero value to any discussion. It's nothing more than a desperate attempt to gain some internet points.

It's a popular language and it has flaws, but that doesn't automatically make it worthy of the amount of hate it receives here. This type of discussion has more in common with /r/iamverysmart than it does with valuable discourse that HN used to be known for.

Re: Structure and Interpretation of Computer Programs – JavaScript Adaptation

#117
post #61

Earlier quoted context omitted.

I don't know anyone who first read this book outside of college. Its concepts aren't exactly directly applicable to typical work. If you're given the task to build something in Javascript for work, it's probably not a metacircular evaluator or a register machine simulator, or even a closure-based object system. I'm curious who's reading SICP who finds it difficult to grok in Scheme, or more useful in Javascript. What…

That might change now. Someone might pick this up after completing a few JavaScript chapters in a JS specific book. I haven't read the book yet so I can't comment on the concepts, but based on your list it's a great resource for any newbie programmer, especially to those who are self taught like me. > What are you doing in the industry that familiar syntax is top priority? The question is more like: "Do I want to inv…

[deleted]

Re: Structure and Interpretation of Computer Programs – JavaScript Adaptation

#118
post #61

Earlier quoted context omitted.

I don't know anyone who first read this book outside of college. Its concepts aren't exactly directly applicable to typical work. If you're given the task to build something in Javascript for work, it's probably not a metacircular evaluator or a register machine simulator, or even a closure-based object system. I'm curious who's reading SICP who finds it difficult to grok in Scheme, or more useful in Javascript. What…

That might change now. Someone might pick this up after completing a few JavaScript chapters in a JS specific book. I haven't read the book yet so I can't comment on the concepts, but based on your list it's a great resource for any newbie programmer, especially to those who are self taught like me. > What are you doing in the industry that familiar syntax is top priority? The question is more like: "Do I want to inv…

It is a great book for self-taught programmers. But the book is about programming language concepts and paradigms, and explores these though the development of multiple languages, interpreters and compilers. It is fundamental to the book that you have to learn a bunch of small languages. Scheme just makes it really easy to implement new languages.

Re: Structure and Interpretation of Computer Programs – JavaScript Adaptation

#119
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

While I certainly wouldn't call JS "great", I actually do genuinely like a lot of parts of it. I like the Lispey style of embedding data structures (hashmaps and arrays) directly into the language, and I like that it has somewhat popularized some functional techniques and made them mainstream.

While callbacks aren't a great way of doing continuation-passing, at least we can credit JS with making continuation-passing mainstream.

In combination with the fact that JS actually does work pretty well on both frontend and backend, it is a language I use semi-regularly for prototyping, given its flexibility. Granted, if I decide to make a "real" version of the project, I'll probably do it with a more functional language, but I think JS doesn't suck too bad.

Re: Structure and Interpretation of Computer Programs – JavaScript Adaptation

#120
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…

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.
Post reply on HN