Hi Simon,
I think that's a very specific usecase and therefor plugin territory. ... Can you describe your usage of this list a bit closer. ... So we may be able, to dynamically create "virtual" lists, that don't stop at 9999
My first question was: "What if I need 10000?" ...
-m
negative and floating numbers with a certain limitation in accuracy would also be great
On Thursday, January 11, 2018 at 1:38:33 PM UTC+1, Simon Huber wrote:negative and floating numbers with a certain limitation in accuracy would also be greatIMO negative numbers can be created with [addprefix[-]]
floating point will be a problem. eg: 0 -> 99.99 will create about 10,000 numbers. So users will create endless loops, without being aware.But you could use nested INTs.
I was thinking about a syntax like: [create[1..100#04]] ... which would mean:start: 1 .. including 1stop: 100 .. including 100format: #04 meansuse leading zerosuse 4 digitswhich would result in 0001 ... 0100 with every number in betweenformat: 1..100#03 means 001 ... 100format: 1..100 means 1 ... 100format: 33..55#03 means 033 ... 055and so on.
Just some thoughts. No promises.
The problem now is, that "start" stop may be variables. ... like [create<start>..<stop>#<format>] ... which is ugly, complex and the parser can't handle it at the moment.
Hey, Simon —See my range operator: http://evanbalster.com/tiddlywiki/formulas.html#range%20Operatoreg. [range[-100,100,.5]] produces -100, -99.5, -99 ... 99, 99.5, 100.It generates evenly-spaced numbers in an arbitrary range, and can deal with whatever step-size you're interested in. The numbers produced never have more decimal points than the arguments and the range is always inclusive.This is a more robust and high-performance implementation than can be managed with TiddlyWiki's built-in mechanisms. It's part of my math & formulas plugin (which I'm designing as a "universal" computation plugin) but it can be used separately. See the attached JSON file.