Difference between revisions of "Template:Rnd/a"

From Chevy Wiki
Jump to navigation Jump to search
m (1 revision)
 
m (1 revision)
 
Line 1: Line 1:
{| class="wikitable" style="margin:0.5em auto; font-size:95%;{{#if:{{{noclear|}}}||clear:both;}}"
<includeonly>{{rnd/c{{rnd/b|abs{{{1}}}|{{{1}}}|{{{2}}}}}|{{{1}}}|{{{2}}}}}</includeonly><noinclude>This is {{tlf|rnd}}'s second step taking input from the main page with the following code.
<noinclude>
 
|''Start of centred table''
*{{lt|rnd}}
|}
<pre>
{{pp-template|small=yes}}
{{formatnum:{{rnd/a|{{#expr:({{{1}}})round({{{2}}})}}|{{{2}}}}}}}
{{documentation}}
</pre>
<!--NB Add metadata to the /doc page linked above, not here; thanks!-->
 
</noinclude>
*{{lt|rnd/a}}
<pre>
{{rnd/c{{rnd/b|abs{{{1}}}|{{{1}}}|{{{2}}}}}|{{{1}}}|{{{2}}}}}
</pre>
 
It calls {{tlf|rnd/b}} which crunches out a code to determine which of the {{tlf|[[:Category:Subtemplates of Template Rnd#C|rnd/c*]]}} subtemplates to go to next.
 
*{{lt|rnd/b}}
<pre>
{{#expr:2*(2+(2-({{{1}}}<10^9)*(2-({{{1}}}/10^5round0={{{1}}}/10^5)))*({{{1}}}>=10^5)-({{{1}}}<0.0001))*(({{{2}}}>0)-({{{2}}}<0))+({{{3}}}>0)}}
</pre>
 
[[Category:Subtemplates of Template Rnd]]</noinclude>

Latest revision as of 15:00, 3 February 2009

This is {{rnd}}'s second step taking input from the main page with the following code.

{{formatnum:{{rnd/a|{{#expr:({{{1}}})round({{{2}}})}}|{{{2}}}}}}}
{{rnd/c{{rnd/b|abs{{{1}}}|{{{1}}}|{{{2}}}}}|{{{1}}}|{{{2}}}}}

It calls {{rnd/b}} which crunches out a code to determine which of the {{rnd/c*}} subtemplates to go to next.

{{#expr:2*(2+(2-({{{1}}}<10^9)*(2-({{{1}}}/10^5round0={{{1}}}/10^5)))*({{{1}}}>=10^5)-({{{1}}}<0.0001))*(({{{2}}}>0)-({{{2}}}<0))+({{{3}}}>0)}}