Page MenuHomeFeedback Tracker

[Request] Range and deviation number comparison commands
Closed, ResolvedPublic

Description

At the moment, if you want to check whether a number is within a range of numbers (e.g. whether 3 is between 2 and 4) you have to combine two > and < checks. This isn't especially taxing but it's a bit clunky and it would be more optimal to have a command for it.

Similarly, if you want to check whether a number is within a certain deviation of another number (e.g. whether 15 is +/- 5 from 10) you have to do some careful comparison structuring. Again, possible but a little awkward and could be made easier.

Proposed solution:

_number range [_max, _min] - returns true if _number is between _max and _min, else false.
_number deviation [_target, _dev] - returns true if _number is between (_target + _dev) and (_target - _dev), else false.

Details

Severity
Feature
Resolution
Open
Reproducibility
N/A
Operating System
Windows 10 x64
Category
Scripting

Event Timeline

NikkoJT created this task.Sat, May 14, 6:03 PM
dedmen closed this task as Resolved.Tue, May 17, 11:17 AM
dedmen claimed this task.
dedmen added a subscriber: dedmen.

Not worth to make commands for something that already works just fine, yes its a bit clunky, but it was good enough for the last 9 years and its still good enough today.