Template:APLFN5: Difference between revisions
No edit summary |
No edit summary |
||
Line 1: | Line 1: | ||
∇ {{{1}}}<br /> | <big> ∇ {{{1}}}<br /> | ||
[1] {{{2}}}<br /> | [1] {{{2}}}<br /> | ||
[2] {{{3}}}<br /> | [2] {{{3}}}<br /> | ||
Line 5: | Line 5: | ||
[4] {{{5}}}<br /> | [4] {{{5}}}<br /> | ||
[5] {{{6}}}<br /> | [5] {{{6}}}<br /> | ||
∇ <br /> | ∇ <br /></big> | ||
<noinclude> | <noinclude> | ||
This template is used to list an APL function having 5 lines. If this wiki adds the Parserfunction feature, this template will be replaced by a generic one. | This template is used to list an APL function having 5 lines. If this wiki adds the Parserfunction feature, this template will be replaced by a generic one. | ||
Line 19: | Line 19: | ||
And you get:<br/> | And you get:<br/> | ||
{{APLFN5|1=K{:=}Header arg1 | {{APLFN5|1=K{:=}Header arg1 | ||
|2='Line1' | |2='Line1' | ||
Line 26: | Line 26: | ||
|5={comment} one more line | |5={comment} one more line | ||
|6-K {:=}1}} | |6-K {:=}1}} | ||
</noinclude> | </noinclude> |
Revision as of 13:08, 27 February 2013
∇ {{{1}}}
[1] {{{2}}}
[2] {{{3}}}
[3] {{{4}}}
[4] {{{5}}}
[5] {{{6}}}
∇
This template is used to list an APL function having 5 lines. If this wiki adds the Parserfunction feature, this template will be replaced by a generic one.
This allows you to list the contents of a function without having to include the line numbers and the ∆ prefix and suffix. You just list the header and the 5 lines. Because of the feature for translating apl symbols, you must specify the line values, Like this:
<apll>{{APLFN5|1=K←Header arg1
|2='Line1'
|3=X←0
|4=rhoresult ← ⍴ X
|5=⍝ one more line
|6-K ←1}}</nowiki></apll>
And you get:
∇ K←Header arg1
[1] 'Line1'
[2] X←0
[3] rhoresult ← ⍴ X
[4] ⍝ one more line
[5] {{{6}}}
∇