Hacker News new | ask | show | jobs
by tonyedgecombe 1771 days ago
No integers. What's the difference between == and ===. Why do I need to learn two ways to declare a class. What module system should I use and why are they all different. Why isn't there much of a standard library. WTF is Grunt, NPM, etc. Just explain 'this' to me again. What is the distinction between null and undefined. What is the difference between for/of and for/in.

JavaScript is far from accessible to new users neither is it simple.

2 comments

You're arguing that javascript doesn't succeed at being accessible to new programmers. I'm not arguing that. I'm saying that javascript nominally values about being accessible to new programmers. There are way more novice programmers using javascript than (almost?) any other language. This isn't an accident.
>This isn't an accident.

No, it's because it's effectively the only option in the browser. If you are going to write front end code then you will end up writing JavaScript in some form or another.

And being popular doesn't necessarily mean it is accessible nor simple. If it had been I doubt we would have seen Python becoming the dominant language in education.

Yep. Python is a dominant language because it also cares a great deal about being easy to learn and accessible to newcomers.

In comparison, C++ does not optimize to be accessible to newcomers. C++ cares a lot more about compiled code running efficiently - as is evident from its insanely complex / powerful templating system. Its hard to learn, but its very powerful. Javascript and Python have nothing like that because that wouldn't align with the values of those languages.

Python values simple code that runs fast enough over complex code that runs super fast. C++ values code running fast enough, even if the code needs to be more difficult to write to achieve that speed.

I agree with most of your points. But the distinction between null and undefined is an important one. Its absence is a legitimate complaint about SQL.