Not exactly true, in some use cases this is correct but in others it doesn't hold. A virtual machine with a garbage collector has some advantages for the optimisation of memory allocation and can actually outperform pure C/C++.It's not as fast as C/C++ but it's probably the next best thing.
For somebody new to programming I would advocate against JavaScript being the first language. Yes node.js has moved JS server side but the language itself is actually rather complex and has a lot of warts and pitfalls that are not obvious to a beginner. JavaScript is essentially Scheme with a Java-like syntax and was developed in a very short period (several months). Get to know a better designed language before diving into JavaScript and when you do use jslint to ensure you don't fall into these traps.
Examples of common gotchas:
- Forgetting to use var for a variable creates a global variable (can have difficult to debug side effects).
- The foreach can have un-expected values unless an appropriate guard is used.
Edited by SledgY, 16 May 2013 - 11:03 AM.