Post Reply 
list slicing question
11-24-2022, 12:04 AM
Post: #2
RE: list slicing question
By trial and error, this seems to work, but weird, with 1 = beyond end-of-list

CAS> range(7)[1:1:2]      → [0,2,4,6]
CAS> range(7)[2:1:2]      → [1,3,5]
CAS> range(7)[3:1:2]      → [2,4,6]
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
list slicing question - Albert Chan - 11-23-2022, 02:55 PM
RE: list slicing question - Albert Chan - 11-24-2022 12:04 AM
RE: list slicing question - Albert Chan - 11-24-2022, 11:32 AM



User(s) browsing this thread: 1 Guest(s)