EasyUse/Logic/Typegenerated

Range(Int)(RangeInt)

The Range(Int) node generates an integer range from a start value to a stop value and returns the first and last values of that range as two INT outputs.

Range Int

range
range_sizes
range_mode
step
start
0
stop
1
step
1
num_steps
0
end_mode
Inclusive
Easy Use

Description

The Range(Int) node generates an integer range from a start value to a stop value and returns the first and last values of that range as two INT outputs. It belongs to the EasyUse/Logic/Type category and is useful whenever you need the endpoints of an arithmetic progression, such as defining iteration bounds or generating numeric ranges for other logic nodes.

Inputs

NameTypeDefaultOptionsDescription
range_modeCOMBOstepstep, num_stepsSelects how the range is computed. step uses the explicit step value; num_steps derives the increment from the number of requested intervals.
startINT0The first value of the range.
stopINT1The boundary value of the range. Whether it is included depends on end_mode.
stepINT1The increment between values when range_mode is step. Can be negative to generate a descending range.
num_stepsINT0The desired number of intervals when range_mode is num_steps.
end_modeCOMBOInclusiveInclusive, ExclusiveInclusive includes stop in the range; Exclusive stops just before stop.

Outputs

OutputTypeDescription
First valueINTThe first value of the generated range.
Last valueINTThe last value of the generated range after applying range_mode, step/num_steps, and end_mode.

Usage Notes

  • Use range_mode = "step" when you already know the exact increment you want between values.
  • Use range_mode = "num_steps" when you want to divide the span from start to stop into a specific number of intervals.
  • end_mode is important when stop must or must not appear as the final value. For example, start = 0, stop = 10, step = 2, and end_mode = "Inclusive" produces a last value of 10; with end_mode = "Exclusive" the last value is 8.
  • Negative steps are supported. For a descending inclusive range, set start above stop and use a negative step.
  • The outputs are scalar integers, not a list. The node returns the boundaries of the computed range, which can then be used by other logic or numeric nodes.

Comments

Sign in with GitHub to join the discussion.

Loading comments…