Each: Difference between revisions
Jump to navigation
Jump to search
(Use internal link instead of external to primitive functions; grammar etc.) |
m (Added the reverse example provided by Adam) |
||
Line 13: | Line 13: | ||
┌───┬───┬───┐ | ┌───┬───┬───┐ | ||
│1 1│1 2│1 3│ | │1 1│1 2│1 3│ | ||
└───┴───┴───┘ | |||
x←'abc' 'def' 'ghi' | |||
⌽x ⍝ reverse x | |||
┌───┬───┬───┐ | |||
│ghi│def│abc│ | |||
└───┴───┴───┘ | |||
⌽¨x ⍝ reverse each element of x | |||
┌───┬───┬───┐ | |||
│cba│fed│ihg│ | |||
└───┴───┴───┘ | └───┴───┴───┘ | ||
</source> | </source> |