data = [1, 2, 3, 4] print(data[:object])
data = [1, 2, 3, 4] print(data[:2])
Used when a slice index is not an integer, None, or an object with an __index__ method.
None
object
__index__