[New Feature] Extend } with }.. to allow direct gap insertions - direct insertion into arrays (9) 1}..1 2 3 4 5 --- 1 9 2 3 1 4 5 #237
solarsystemic
started this conversation in
Ideas
Replies: 1 comment
-
|
No new glyphs. This would need to handle multiaxis insertion/modification, and matching of cells of x to m as with m} |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
one current approach for insertion.
z=.1 0 1 #^:_1 'ab'
]z=.'a' (1)}z
'aab'
shorter:
'a' (1)} (1 0 1 #^:_1 'ab') --- 'aab'
for more direct gap insertion with }..
'a' (1)}.. 'ab' --- 'aab'
with }.. or..... some other glyph.
(9) 1}..1 2 3 4 5 --- 1 9 2 3 4 5
(9) 0}..1 2 3 4 5 --- 9 1 2 3 1 4 5
(9) 5}.. 1 2 3 4 5 --- 1 2 3 4 5 9
(9 10 11) 2}..1 2 3 4 5 --- 1 2 9 10 11 3 4 5
(9 10 11) 2 3 }..1 2 3 4 5 --- 1 2 9 10 11 3 9 10 11 4 5
(9) 1}.."1 ( i. 2 2) ---
0 9 1
2 9 3
(9) (1+#z)}.."1 ( z=.i. 2 2) ---
0 1 9
2 3 9
Uiua uses glyph completion (Mnemonic glyph completion from ASCII sequences) and that enables new glyphs. No need for a new keyboard or labels. Perhaps '⋔' for gap insertion. Maybe direct gap insertion allows in-place.
Beta Was this translation helpful? Give feedback.
All reactions