<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def array(self):
 """ Returns a numpy array containing the last stored values. """

        if self._ind < self.shape:
            return self._values[:self._ind]
        if not self._cached:
            ind = int(self._ind % self.shape)
            self._cache[:self.shape - ind] = self._values[ind:]
            self._cache[self.shape - ind:] = self._values[:ind]
            self._cached = True
        return self._cache