Difference between revisions of "Template:Rnd/-"

From Chevy Wiki
Jump to navigation Jump to search
m (1 revision)
 
m (1 revision)
 
Line 1: Line 1:
<includeonly>{{#ifexpr:{{{2}}}=0|0|{{#ifexpr:{{{2}}}<0|-}}{{#ifexpr:{{{1}}}<10^5|{{#ifexpr:{{{1}}}<0.0001|2|4}}|{{#ifexpr:{{{1}}}<10^9|{{#ifexpr:{{{1}}}/10^5round0={{{1}}}/10^5|6|4}}|8}}}}}}dec{{#expr:{{{3}}}>0}}</includeonly><noinclude>This subtemplate is called by {{tl|rnd/a}} to produce a code to determine what to do next.
<includeonly>{{#expr:{{{1}}}}}<!--
-->{{#ifexpr: {{{2}}}>0  and {{{1}}}={{{1}}}round0 |.0}}<!--
-->{{#ifexpr: {{{2}}}>1  and {{{1}}}={{{1}}}round1  |0}}<!--
-->{{#ifexpr: {{{2}}}>2  and {{{1}}}={{{1}}}round2  |0}}<!--
-->{{#ifexpr: {{{2}}}>3  and {{{1}}}={{{1}}}round3  |0}}<!--
-->{{#ifexpr: {{{2}}}>4  and {{{1}}}={{{1}}}round4  |0}}<!--
-->{{#ifexpr: {{{2}}}>5 and {{{1}}}={{{1}}}round5  |0}}<!--
-->{{#ifexpr: {{{2}}}>6  and {{{1}}}={{{1}}}round6  |0}}<!--
-->{{#ifexpr: {{{2}}}>7  and {{{1}}}={{{1}}}round7  |0}}<!--
-->{{#ifexpr: {{{2}}}>8  and {{{1}}}={{{1}}}round8  |0}}<!--
-->{{#ifexpr: {{{2}}}>9 and {{{1}}}={{{1}}}round9  |0}}<!--
-->{{#ifexpr: {{{2}}}>10 and {{{1}}}={{{1}}}round10 |0}}<!--
-->{{#ifexpr: {{{2}}}>11 and {{{1}}}={{{1}}}round11 |0}}<!--
-->{{#ifexpr: {{{2}}}>12 and {{{1}}}={{{1}}}round12 |0}}<!--
--></includeonly><noinclude>{{pp-template}}Adds trailing zeros:


[[Category:Subtemplates of Template Rnd]]</noinclude>
*{{xpd|rnd/-|2|3}}
 
Used by {{tiw|rnd}}:
*{{xpd|#expr:2.0004 round 3}}
*{{xpd|rnd|2.0004|3}}
[[Category:Subtemplates of Template Rnd]]
</noinclude>

Latest revision as of 15:00, 3 February 2009

Adds trailing zeros:

  • "{{rnd/-|2|3}}" gives "2.000" [1]Template:Xpd/

Used by Template:rnd (backlinks, edit):

  • {{#expr:2.0004 round 3}} gives 2 [2]Template:Xpd/
  • "{{rnd|2.0004|3}}" gives "2.000" [3]Template:Xpd/