Template:interval
Appearance
- The following documentation is located at Template:interval/documentation. [edit]
- Useful links: subpage list • links • redirects • transclusions • errors (parser/module) • sandbox
Switch between adjacent intervals.
Parameters
|p=
Position-X|1=
Interval-1|2=
Interval-2|3=
Interval-3|N=@
Interval-N = default value (use '@' to display '@')|default=
Default value
Examples
- Match 10 with some interval: [3...9) [9...12) [12...∞)
{{interval|p=10|3=three|9=nine|12=twelve}}
- nine
{{interval|p=2|1=one|2=@|3=three|default=other}}
- other
{{interval|p=2|1=one|2=@|3=three|default=other}}
- @
Synonyms
{{#switch:{{#expr:(10>=3)+(10>=9)+(10>=12)}}|1=three|2=nine|3=twelve}}
- nine
{{#switch:1|{{#expr:(10>=12)}}=twelve|{{#expr:(10>=9)}}=nine|{{#expr:(10>=3)}}=three}}
- nine
Comparison
This: Syn1: Syn2: . |
0.026±0.011 0.003 0.003 s |
0.030±0.010 0.003±0.001 0.003±0.001 s |
13 6 7 10^6 |
8 5 6 byte |
0 0 0 byte |
3 3 3 100 |
0 0 0 500 |
0 0 0 20 |
0 0 0 byte |
0 -- -- s |
567846 -- -- byte |
0 0 0 400 |