In my latest App I have 2 arrays and I would like to pick an index of the first array, which contains similar words like any index of the first array.
The goal is to pick the index of the first array, that contains words which the user has put in his "favourites" (second array).
1. Dog Flower Cat
2. The cool cat
1. ??? ??? ???
2. Flower Cat Smiley
In this case, the first index of the first array contains two matching words with the second index of the second array so the program should pick the first index of the second array.
Hopefully this explains my problem a little better .
I just tried to do it with many loops but I actually lost the overview :/ .
Does anyone know of an easy way to do it?
Any help is appreciated!