Join our free community Discord server here!
Don't have a portfolio? Create one in our new workshop using React!
Learn React with us!
Get job-ready with our Career Toolbox Track's career advice, resume tips, and more 🧰
🤖 Check out all our AI content here 👀
Bummer! This is just a preview. You need to be signed in with an account to view the entire instruction.
Now that you know a little bit more about the difference between a tuple and a list, let's take a look at one.
Here we have a python list:
# A list
groceries = ['apples', 'oranges', 'lettuce', 'cheddar cheese']
To convert this list to a tuple, we can do one of two things: remove the square brackets entirely, or replace them with parentheses.