Answers for "difference list and set python"

2

difference between set and list in python

'''
In python, a list is a collection of values in a specific order.
There can be several times the same value
[4,8,9,5,4,1,3,4] is a valid list in python

In a set, all values has to be unique.
It is better to use sets compared to lists as much as possible,
because of its speed to retrieve data and space memory economy.
Diferent methods are available for sets and lists.
I will let you discover them on this well-done website : 
https://www.datacamp.com/community/tutorials/sets-in-python
'''
Posted by: Guest on June-12-2021

Code answers related to "difference list and set python"

Python Answers by Framework

Browse Popular Code Answers by Language