python切片操作
提問人:楊紫紅發(fā)布時間:2020-11-26
切片操作
a = [2, 3, 4, 5, 6]
a[:2] #[2, 3]
a[2:] #[4, 5, 6]
a[2:4] #[4, 5]
a[:] # [2, 3, 4, 5, 6]
繼續(xù)查找其他問題的答案?
相關視頻回答
切片操作
a = [2, 3, 4, 5, 6]
a[:2] #[2, 3]
a[2:] #[4, 5, 6]
a[2:4] #[4, 5]
a[:] # [2, 3, 4, 5, 6]
點擊加載更多評論>>