Simple:
[3 0 1 2 1 0 3 3 0 2 3 3 1 2 2 2 2 1 0 2] 1 ef --> [2 4 12 17]
It would also be nice if this worked with multi-dimensional arrays, but I think that should probably be part of a larger change, which also allows for multi-dimensional =, t, /, %, ew etc.
=
t
/
%
ew
Would also be good if this took a block, like #
#
Equally useful might be a get-indicies-of-truthy-elements operator, such that the above could be implemented as f=x (assuming x is said operator).
f=x
x
Log in to post a comment.
Would also be good if this took a block, like
#
Equally useful might be a get-indicies-of-truthy-elements operator, such that the above could be implemented as
f=x
(assumingx
is said operator).