def METHOD_NAME(self, i:int):
    """
    Get value at given index where
    head is index 0 and tail is is index count-1;
    i: index from 0 to count-1 (head is zero)
    return: value at index
            or the default value if index is out of range
    """
    if (i >= 0) and (i < self.count):
        return self.buffer[(self.tailIndex + (self.count + i - 1)) % self.capacity]
    return self.defaultValue