Available in: Redis Stack
Time complexity: O(n) where n is the number of items
Checks whether an item is one of Top-K items. Multiple items can be checked at once.
[] - "1" if item is in Top-K, otherwise "0".
redis> TOPK.QUERY topk 42 nonexist
1) (integer) 1
2) (integer) 0