http://qs1969.pair.com?node_id=2359


in reply to How do I find the index of the last element in an array?

You can also use negative array indexes:
my @demo = ("one", "two", "three", "four"); print $demo[-1];
The result is "four".