# 2021-01-05 #「Python」- 数据类型(学习笔记)
相关链接
用于存储数据集的四种数据类型
Python Sets / Python Lists / Python Dictionaries / Python Tuples
List、Set、Dictionary、Tuple:
Type | Example | Features |
---|---|---|
Tuple | (1, 2, 3, 4) | ordered, unchangeable, allow duplicates |
List | [1, 2, 3, 4] | ordered, changeable, allow duplicates |
Set | {1, 2, 3, 4} | unordered, unchangeable, do not allow duplicates |
Dictionary | {"a": 1, "b": 2, "c": "3", "d": "4"} | unordered, changeable, does not allow duplicates |