all parms random randomize randomize_vs_shuffle total
There are main 3 ways for randomizing, a sequence (random), an option (randomly) and an action (randomize)
The sequence 'random'
|
HTML
|
RESULT
|
{sequence random, rows=25, minimal=10, maximal=50 } {$sequence} {/sequence}
|
32 12 21 15 23 39 32 44 20 21 19 17 10 39 33 13 41 45 21 29 16 16 30 32 48
|
{sequence random, rows=25, minimal=10, maximal=50, unique } {$sequence} {/sequence}
|
13 12 18 42 27 14 10 47 32 17 45 16 30 29 39 43 48 49 34 41 22 36 11 33 46
|
The sequence option 'randomly'
Here the loop index is randomly set before the sequence is executed.
|
HTML
|
RESULT
|
{sequence power=2, rows=10, randomly, from=8, to=16} {$sequence} {/sequence}
|
2048 1024 32768 2048 32768 16384 256 1024 32768
|
{sequence prime, rows=10, randomly, to=1000 } {$sequence} {/sequence}
|
83 977 127 359 367 829 937 919 839 953
|
The sequence action 'randomize'
|
HTML
|
RESULT
|
{sequence from=10, to=20, push='mySeq'}
|
|
{mySeq} {$sequence} {/mySeq}
|
10 11 12 13 14 15 16 17 18 19 20
|
{mySeq randomize } {$sequence} {/mySeq}
|
19 14 11 15 16 13 20 12 10 18 17
|
{mySeq randomize=5} {$sequence} {/mySeq}
|
14 16 20 10 19
|
|