Ravel: Difference between revisions

Jump to navigation Jump to search
m (Text replacement - "{{APL built-ins}}" to "{{APL built-ins}}Category:Primitive functions")
m (Text replacement - " ⊢( *[^∘])" to " ⎕←$1")
Tags: Mobile edit Mobile web edit
Line 9: Line 9:
You can use ravel to squash a [[matrix]] down to one dimension. The elements are listed in reading order—left to right, top to bottom.
You can use ravel to squash a [[matrix]] down to one dimension. The elements are listed in reading order—left to right, top to bottom.
<source lang=apl>
<source lang=apl>
       ⊢x ← 3 4⍴⍳12            ⍝ A matrix
       ⎕←x ← 3 4⍴⍳12            ⍝ A matrix
1  2  3  4
1  2  3  4
5  6  7  8
5  6  7  8
Retrieved from ‘https://aplwiki.com/wiki/Ravel