Matrix transposition: Difference between revisions
Content added Content deleted
(Added J solution. I'll add an example soon.) |
(→{{header|J}}: Added example.) |
||
Line 164: | Line 164: | ||
=={{header|J}}== |
=={{header|J}}== |
||
Transpose is the monadic primary verb <code>|:</code> |
Transpose is the monadic primary verb <code>|:</code> |
||
]matrix=: 3 5 $ 10+ i. 15 NB. show example matrix |
|||
10 11 12 13 14 |
|||
15 16 17 18 19 |
|||
20 21 22 23 24 |
|||
|: matrix |
|||
10 15 20 |
|||
11 16 21 |
|||
12 17 22 |
|||
13 18 23 |
|||
14 19 24 |
|||
=={{header|Java}}== |
=={{header|Java}}== |