A slice of an empty list is still an empty list.
But a slice of an empty array (or beyond the present size of the array) is a list of undefs.
So:
CountZero
A program should be light and agile, its subroutines connected like a string of pearls. The spirit and intent of the program should be retained throughout. There should be neither too little or too much, neither needless loops nor useless variables, neither lack of structure nor overwhelming rigidity." - The Tao of Programming, 4.1 - Geoffrey James
My blog: Imperial DeltronicsIn reply to Re: Array slices: beyond the end/ Assigning an empty list to a Hash slice
by CountZero
in thread Array slices: beyond the end/ Assigning an empty list to a Hash slice
by 7stud
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |