Loops/For: Difference between revisions
→{{header|APL}}
m (→{{header|Commodore BASIC}}: formatting) |
|||
Line 340:
<lang APL>{⎕←⍵/'*'}¨⍳5</lang>
However, to stick to the letter of the task description, we can nest an '''each''' inside another one. This becomes less portable as it relies on '''⎕ucs''' to generate a newline, assumes that newline is character 10, and requires support for multiple statements inside an anonymous function (dfn, <tt>{</tt> ... <tt>}</tt>), which e.g. GNU APL does not have:
{{works with|Dyalog APL}}
<lang APL>{_←{⍞←'*'}¨⍳⍵ ⋄ ⍞←⎕ucs 10}¨⍳5</lang>
|