Add half closed interval for repetition

The range of between can contain `nil` for half closed interval.