« first day (262 days earlier)
← previous day
next day →
last day (1273 days later) »
rcabaco
10:16 PM
1 -1 0"az"?"a..z"
1 0 0 -1
is this documented somewhere?
it works in k7 and q/k4
i saw it in some q code
can't seem to find it in q ref
ktye
what do you mean? x?y is find "az"?"a..z" returns the indexes of y in x and #x if it is not found. This might be 0N in some versions of k.
1 -1 0... next to "az"... is like indexing 1 -1 0@...
rcabaco
"az"?"a..z"
0 2 2 1
isn't the 1 -1 0 giving find the values for the matches?
1 for a; -1 for z; 0 for not found
or am i reading this wrong?
ktye
no this is a separate expression. you have:
1 -1 1@("az"?"a..z")
find only sees "az" and "a..z"
rcabaco
ahhh
dumb me
i get it
thank you
the @ is implicit there somehow
what is/are the rules for that?
ktye
10:31 PM
@rcabaco some call it juxtaposition. putting two things side-by-side is an implicit @, such as a:"abc"; i:0 2 then a@i or a i is the same thing.
rcabaco
ok, need to pay more attention
and use
p@ more often (or just
p)
« first day (262 days earlier)
← previous day
next day →
last day (1273 days later) »
all rooms
Transcript for
Nov
24
Nov '19
25
Nov
26
the k tree
app.element.io/#/room/#ngnk:matrix.org
join this room
about this room
00:00
06:00
12:00
18:00
all times are UTC
site design / logo © 2024 Stack Exchange Inc;
legal
mobile