<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def add(self, interval, offset):
 """ The added interval must be overlapping or beyond the last stored interval ie. added in sorted order. :param interval: interval to add :param offset: full virtual offset to add :return: """

        start, stop = self.get_start_stop(interval)

        if len(self.starts) > 0:
            if start < self.starts[-1] or offset <= self.offsets[-1][1]:
                raise ValueError('intervals and offsets must be added in-order')
            self.offsets[-1][1] = offset
            self.offsets[-1][2] += 1
        else:
            self.starts.append(start)
            self.stops.append(stop)
            self.offsets.append([offset, offset, 1])