PHP reset() Function

The reset() function used to move the array's internal pointer to the first element.The reset() function moves the internal pointer to the first element of the array.reset — Set the internal pointer of an array to its first element.reset() rewinds array's internal pointer to the first element and returns the value of the first array element.Returns the value of the first array element, or FALSE if the array is empty.

Example -

Example -