Determines if a number is within a specified range.
The number to test.
The lower bound of the range.
The upper bound of the range.
Whether the range includes the bounds (default: true).
True if the number is within the range, false otherwise.
inRange(5, 1, 10); // true (inclusive by default)inRange(1, 1, 10); // trueinRange(10, 1, 10, false); // false (exclusive)inRange(5, 6, 10); // false Copy
inRange(5, 1, 10); // true (inclusive by default)inRange(1, 1, 10); // trueinRange(10, 1, 10, false); // false (exclusive)inRange(5, 6, 10); // false
Determines if a number is within a specified range.