Another useful data type is the string. A string can contain letters, numbers, and symbols.

name = "Ryan" age = "19" food = "cheese"
  1. In the above example, we create a variable name and set it to the string value "Ryan".
  2. We also set age to "19" and food to "cheese".

Strings need to be within quotes.



Create a new variable brian and assign it the string "Hello life!".

Take this course for free

Mini Info Outline Icon
By signing up for Codecademy, you agree to Codecademy's Terms of Service & Privacy Policy.

Or sign up using:

Already have an account?