Arrays to vector conversion

A merge of @sijo and @DNF solutions, that is short and non-allocating:

all(isapprox(only(x), y; atol=1e-5) for (x,y) in zip(a,b))

However, these non-allocating approaches do not seem to do exactly the same as OP, because for vector inputs a vector norm is used.

1 Like