When we run this, you will notice a nice little error. The quotation mark before this is actually ending that string. Your browser is freaking out because it doesn't know what to do with the following this food is to die for" seems like it lacks logic." when it just expected a ; , which is the actual error.
Welcome to the power of the escape character. As you can see, adding a solved our problem. The escape character doesn't stop being awesome with just quotation marks.
- \' - escapes a single quote
- \" - escapes a double quote
- \\ - escapes a backslash
- \n - creates a new line
Your code will execute in this window.
Let's explore some more tutorials or topics!
No comments yet... Be the first!