make find, filter, count more consistent

They all accept the three following forms:
1. f(pred, A) -> pred is applied to all A elements
2. f(A, val)  <==> f(x -> x == val)
3. f(A)       <==> f(x -> x != 0)
deprecate countnz