Tricky JavaScript Questions

This hard JavaScript quiz goes after the language's strangest corners. You will untangle coercion, parseInt with map, object keys, the temporal dead zone and automatic semicolon insertion, and explain why each result happens.

Schwer 10 Fragen ~8 Minuten Bestanden ab 80% Node.js 22

Modus wählen

Du spielst als Gast: Melde dich an, damit XP und Serie gespeichert werden.

Beispielfrage

Frage 1 von 10

What does this print?

console.log([] + {}, typeof ([] + {}));
Lösung zeigen

B. [object Object] string + with objects converts both sides to primitives: [] becomes "" and {} becomes "[object Object]". One of them is a string, so the result is string concatenation.

Darum geht es in diesem Quiz

  • Coercion of arrays and objects to strings and booleans
  • map(parseInt) and other argument surprises
  • Objects used as property keys
  • The temporal dead zone of let
  • Automatic semicolon insertion after return

Häufige Fragen

Brauche ich ein Konto?

Nein. Jeder kann spielen. Mit Anmeldung werden XP, Serie, Abzeichen und Verlauf gespeichert.

Kann ich es wiederholen?

Ja. Dein Bestwert bleibt erhalten, und Fragen und Antworten werden jedes Mal neu gemischt.