Am 05.03.2018 um 01:57 schrieb Allin Cottrell:
On Sun, 4 Mar 2018, Sven Schreiber wrote:
> In principle, yes. However, maybe it's worth pointing out
that if we
> had a function to stuff all the array elements together (say,
> 'concat'), then it would just be a matter of doing:
>
> strstr(concat(mystrings), "findme")
What if the array contained an element "findmeNOT", but no element
"findme"?
Good point. In analogy to 'strsplit' the function 'concat' could anyway
use a second optional argument that specifies a joining character. Then
it would be possible to do:
strstr(concat(mystrings, ","), ",findme,")
At least that would cover the problem of searching bundle keys because
commas are not allowed there. But of course it wouldn't be a general
equivalent to an inarray function. And I admit it's much less attractive.
thanks,
sven