Python Python Basics (2015) Python Data Types List Creation

where have i gone wrong? seems logical what i have put together

please help
[blue, black, red, yellow, white]
"color" = [blue, black, red, yellow, white]

1 Answer

28,465 Points

The first line is not really needed and contain some errors, as far as the second line goes there are two issues:

  1. You have named the variable color instead of colors which is what the task asked for, naming it exactly what is requested is important when doing a challenge.

  2. You have your quote usage the wrong way around. The names of variables should not be enclosed in quotes, arbitrary words like the colors you have placed in the list should be enclosed in quotes though, as they are strings.

So if you remove the first line and fix the issues I pointed out like this:

colors = ["blue", "black", "red", "yellow", "white"]

Then your code will be accepted.