@{$href}{"one", "two", "three"}; # hash slice, hashref @hash {"one", "two", "three"}; # hash slice, hash for (0 .. $#{$aref}) {} # index iteration, arrayref for (0 .. $#array) {} # index iteration, array # with references @{$aref2} = map { $href1->{$_} + 1 } sort { $href2->{$a} <=> $href2->{$b} } grep /foo/, @{$aref1}[0 .. $#{$aref1}/2]; # without @array2 = map { $hash1{$_} + 1 } sort { $hash2{$a} <=> $hash2{$b} } grep /foo/, @array1[0 .. $#array1/2];