use first & last instead array[index]