The Workshop contains quiz questions and exercises to help you solidify your understanding of the material covered. Try to answer all questions before looking at the answers that follow.
- What characters can be stored in strings?
- What math operators work with strings?
- What is the backslash character (\) called? What is it used for?
- Alphabetic characters, numbers, and symbols can all be stored in strings, as well as whitespace characters such as spaces and tabs.
- Addition and multiplication operators work with strings.
- The backslash is called an “escape” and indicates that you want to include some special formatting, such as a tab, new line, a single or double quote, or a backslash.
In your program, you’re given a string that contains the body of an email. If the email contains the word “emergency,” print out “Do you want to make this email urgent?” If it contains the word “joke,” print out “Do you want to set this email as non-urgent?”