Code: Select all
r←ScriptFollows;dtlb
⍝ treat following commented lines in caller as a script, lines beginning with ⍝⍝ are stripped out
dtlb←{⍵{((∨\⍵)∧⌽∨\⌽⍵)/⍺}' '≠⍵}
r←{∊{'⍝'=⊃⍵:'' ⋄ ' ',dtlb ⍵}¨1↓¨⍵/⍨∧\'⍝'=⊃¨⍵}dtlb¨(1+2⊃⎕LC)↓⎕NR 2⊃⎕XSI
The function is using (⎕IO ⎕ML)←0 3
Anyone using something similar to input matrix of characters in a function that would like to share is welcome.