Skip to content

Instantly share code, notes, and snippets.

@im4aLL
Created April 3, 2024 17:37
Show Gist options
  • Save im4aLL/26234d5bcd0bde8e90f19df50852d182 to your computer and use it in GitHub Desktop.
Save im4aLL/26234d5bcd0bde8e90f19df50852d182 to your computer and use it in GitHub Desktop.
emotional abuse
// 1
console.log(typeof typeof 1);
// 2
console.log(018 - 015);
// 3
const numbers = [33, 2, 8];
numbers.sort();
console.log(numbers[1]);
// 4
console.log(false == '0');
// 5
console.log(0.1 + 0.2 == 0.3);
// 6
let array = [1, 2, 3];
array[6] = 9;
console.log(array[5]);
// 7
const isTrue = true == [];
const isFalse = true == ![];
console.log(isTrue + isFalse);
// 8
console.log(1 + '2' + '3');
// 9
console.log(String.raw`Hello\nWorld`);
// 10
console.log("I am a string" instance of String);
// 11
console.log(3 > 2 > 1);
// 12
console.log(('b' + 'a' + + 'a' + 'a').toLowerCase());
// 13
console.log(typeof NaN);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment