Difference between revisions of "Template:Convert/round"

From Teampedia
Jump to: navigation, search
(Created page with "<includeonly>{{#ifexpr:{{{2}}}=0|0|{{formatnum:{{rnd|{{{2}}}|({{max/2|{{#expr:({{precision/2010|1{{{1}}}}}+{{{5}}}-0.5+(ln2/ln10))round0}}|{{#expr:1-{{Order of magnitude|{{{2}...")
 
Line 1: Line 1:
<includeonly>{{#ifexpr:{{{2}}}=0|0|{{formatnum:{{rnd|{{{2}}}|({{max/2|{{#expr:({{precision/2010|1{{{1}}}}}+{{{5}}}-0.5+(ln2/ln10))round0}}|{{#expr:1-{{Order of magnitude|{{{2}}}}}}}}})}}}}}}</includeonly><noinclude>{{pp-template}}
+
{{#ifexpr: {{{2<noinclude>|1234.5678</noinclude>}}}=0
[[Category:Subtemplates of Template Convert]]{{pp-template|small=yes}}
+
| 0
</noinclude>
+
| {{formatnum:{{Rnd
 +
    | 1 = {{{2<noinclude>|1234.5678</noinclude>}}}
 +
    | 2 = {{Max/2
 +
      | 1 = {{#expr:({{Precision
 +
        | 1 = 1{{{1<noinclude>|2</noinclude>}}}
 +
        }})+({{{5<noinclude>|0</noinclude>}}})-0.5+ln2/ln10round0}}
 +
      | 2 = {{#expr:1-{{Order of magnitude
 +
        | 1 = {{{2<noinclude>|1234.5678</noinclude>}}}
 +
        }}}}
 +
      }}
 +
  }}}}
 +
}}<noinclude>
 +
 
 +
<!--{{pp-template|small=yes}}-->
 +
{{Documentation|content=
 +
== Usage ==
 +
* "{{T|Convert/round|1|1234.5678}}" gives "{{Convert/round|1|1234.5678}}".
 +
 
 +
[[Category:Subtemplates of Template Convert]]
 +
}}</noinclude>

Revision as of 13:24, 11 April 2020

{{rnd/bExpression error: Unexpected < operator.|Expression error: Missing operand for round.||Expression error: Unexpected > operator.}}

Documentation icon Template documentation

Usage

Editors can experiment in this template's sandbox (create | mirror) and testcases (create) pages.
Subpages of this template.