Arrayarray_slice (array $ array, int $ offset [, int $ length [, bool $ preserve_keys]) array_slice () returns a sequence of arrays specified by the offset and length parameters. If offset is not negative, the sequence starts from this offset in array. If offset is negative, the sequence starts from the end of the array so far (what does this mean ). $ Inputarray (& quo php
Array array_slice (array $ array, int $ offset [, int $ length [, bool $ preserve_keys])
Array_slice () returns a sequence in the array specified by the offset and length parameters.
If offset is not negative, the sequence starts from this offset in array. If offset is negative, the sequence starts from the end of the array so far (what does this mean ).
$ Input = array ("a", "B", "c", "d", "e ");
$ Output = array_slice ($ input,-1); // returns "e"
If it is one left shift from the end of 'e', shouldn't it be 'D ??