Reputation: 39
Say I have a list
b:1 1 2 3 4
and I want to find the location of the element in list b using another list
a:1 2
When I type in b in\ a
, I got
11000b
00000b
where it should be
11000b
00100b
What is going on and how to get the desired answer?
Thanks in advance!
Upvotes: 3
Views: 865
Reputation: 5644
You need to use each-right /:
q)b in/:a
11000b
00100b
With b in\a
the first output is getting passed back in as b
. Effectively:
q)1 1 2 3 4 in 1
11000b
q)11000b in 2
00000b
Upvotes: 2