JavaScript-Quiz: Strings & Template Literals

This JavaScript strings quiz checks template literals and the everyday string methods. You will predict the output of slice, split, trim and at, and see that strings can't be changed in place.

Leicht 10 Fragen ~5 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?

const name = "Ann";
console.log(`Hi, ${name}!`);
Lösung zeigen

D. Hi, Ann! Inside backticks, ${...} is replaced by the value of the expression. With normal quotes the text ${name} would be printed as is.

Darum geht es in diesem Quiz

  • Template literals with backticks and ${...}
  • Cutting strings with slice() and split()
  • trim(), toUpperCase() and at()
  • Strings are immutable
  • Searching with includes()

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.