KnowledgeHub
Questions
Tags
Users
Search
Alex Rivera
|
Logout
Edit Question
Title
Body
If I have an array myarray in Python, I can use the slice notation myarray[0::2] to select only the even-indexed elements. For example: >>> ar = [ "zero", "one", "two", "three", "four", "five", "six" ] >>> ar [ 0 : : 2 ] ['zero', 'two', 'four', 'six'] Is there a similar facility in Perl?
Tags (comma-separated)
Save Edits
Cancel