Javascript Weird Parts -

console.log(y); // outputs ReferenceError let y = 10;

Type coercion is JavaScript's attempt to be "helpful" by automatically converting one data type into another during operations. While convenient, it often produces results that seem like nonsensical riddles. javascript weird parts

Use a small epsilon or multiply by powers of 10 for money calculations (or use BigInt for integers). console

JavaScript’s weird parts aren’t bugs—they’re historical artifacts. Brendan Eich built this language in in 1995. It had to be flexible, forgiving, and fast. and fast. const arr = [1

const arr = [1, 2, 3]; const obj = { a: 1 };