Files
JeanMendes bdc7c22ee6 Update "Escape Sequences in Strings" stub (#34006)
* Update "Escape Sequences in Strings" stub

* fix: replaced backspace with word boundary
2019-03-08 14:47:58 -08:00

588 B
Raw Blame History

title
title
Escape Sequences in Strings

Escape Sequences in Strings

  • Escape sequences allow you to use characters you might not otherwise be able to type out, such as a word boundary.
  • By following this diagram with character combinations you will be able to assign escape sequences to the string.
  • single quote
  • " double quote
  • \ backslash
  • \n new line
  • \r carriage return
  • \t tab
  • \b word boundary
  • \f form feed
  • The challenge requires that you don't use space between characters.

Solution

var myStr = "FirstLine\n\t\\SecondLine\nThirdLine";