Difference between revisions of "Template:AIME box"

(->colon)
(fixing, since no parser functions)
Line 1: Line 1:
 
{{Succession box
 
{{Succession box
|before={{#ifeq:+1|{{{problem}}}|First<br />question|[[{{{year}}} AIME Problems/Problem {{#expr:{{{problem}}}-1}}]]}}
+
|before={{{before|[[{{{year}}} AIME Problems/Problem {{{num-b}}}]]}}}
 
|title=[[AIME]]<br />[[{{{year}}} AIME Problems|{{{year}}}]]
 
|title=[[AIME]]<br />[[{{{year}}} AIME Problems|{{{year}}}]]
|after={{#ifeq:+15|{{{problem}}}|Last<br />question|[[{{{year}}} AIME Problems/Problem {{#expr:{{{problem}}}+1}}]]}}
+
|after={{{after|[[{{{year}}} AIME Problems/Problem {{{num-a}}}]]}}}
 
}}<noinclude>
 
}}<noinclude>
 
To use this template, type in:
 
To use this template, type in:
  
 
<pre>
 
<pre>
{{AIME box|year=|problem=}}
+
{{AIME box|year=|num-b=|num-a=}}
 
</pre>
 
</pre>
 +
 +
Where num-b is the problem number before the current one, and num-a is the problem number after the current one (this is because [http://meta.wikimedia.org/wiki/ParserFunctions parser functions] are not supported).
  
 
For example,
 
For example,
 
<pre>
 
<pre>
{{AIME box|year=1986|problem=2}}
+
{{AIME box|year=1986|num-b=1|num-a=3}}
 +
</pre>
 +
 
 +
If it is the first question, then use:
 +
<pre>
 +
{{AIME box|year=|before=First<br />Question|num-a=2}}
 +
</pre>
 +
 
 +
If it is the last question, then use:
 +
<pre>
 +
{{AIME box|year=|num-b=14|after=Last<br />Question}}
 
</pre>
 
</pre>
  
 
This yields:
 
This yields:
  
{{AIME box|year=1986|problem=2}}
+
{{AIME box|year=1986|num-b=1|num-a=3}}
 +
 
 +
{{AIME box|year=|before=First<br />Question|num-a=2}}
 +
 
 +
{{AIME box|year=|num-b=14|after=Last<br />Question}}
  
 
[[Category:Succession templates]]
 
[[Category:Succession templates]]
 
</noinclude>
 
</noinclude>

Revision as of 17:16, 29 January 2007

{{{header}}}
Preceded by
[[{{{year}}} AIME Problems/Problem {{{num-b}}}]]
AIME
[[{{{year}}} AIME Problems|{{{year}}}]]
Followed by
[[{{{year}}} AIME Problems/Problem {{{num-a}}}]]

To use this template, type in:

{{AIME box|year=|num-b=|num-a=}}

Where num-b is the problem number before the current one, and num-a is the problem number after the current one (this is because parser functions are not supported).

For example,

{{AIME box|year=1986|num-b=1|num-a=3}}

If it is the first question, then use:

{{AIME box|year=|before=First<br />Question|num-a=2}}

If it is the last question, then use:

{{AIME box|year=|num-b=14|after=Last<br />Question}}

This yields:

1986 AIME (ProblemsAnswer KeyResources)
Preceded by
Problem 1
Followed by
Problem 3
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
All AIME Problems and Solutions
AIME (ProblemsAnswer KeyResources)
Preceded by
First
Question
Followed by
Problem 2
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
All AIME Problems and Solutions
AIME (ProblemsAnswer KeyResources)
Preceded by
Problem 14
Followed by
Last
Question
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
All AIME Problems and Solutions