Language pitfalls
What do you mean "true does not equal true"... what planet is this?
General pitfalls across languages
Whether 2 + 2 = 4 is never as simple as it might seem...
Asynchronous code pitfalls
Using Promises incorrectly Not respecting the order of code execution can have unexpected result...
Null comparisons and falsey values
Some languages have weird rules for null comparisons and falsey values; try to keep that in mind ...
Passing by value vs reference
In some languages, you have to pay attention to using variables from a greater scope (e.g. a glob...
JavaScript
"It's not Java!!"
JavaScript does not support 64-bit integers
In most languages, a long is a 64-bit integer, for use when a 32-bit integer isn't big enough. Ja...
JSON.stringify
Certain objects (like Maps) can't be stringified directly - you'll get an empty object as the res...
Variable evaluation and race conditions
Suppose we have some code like this: // elementsArray is an array of 10 jQuery objects for (let...
PHP
Warning: undefined array key "brain" on line 5
Java
"It's not JavaScript!!"