procedure search(list, key)
results = empty list
l = length of list
for i from 0 to l -1 step 1
if list.get item at index(i) = key
results.add(i)
return results
list = (hello hi test hello)
search(list, "hello") // returns (1 4)
It worked perfectly, it was exactly what I wanted. Taking advantage of the subject, I wonder if there is a way to send this information to a second screen?
It worked perfectly, I don’t know if you forgot a block for me to take a look at or you really did, I put the block to replace and get the IDs and now it’s working perfectly, I didn’t think it could be done this way …
Hi,
This guide of the search bar is very nice and I am going to use this in my next app. But, I want that after searching if they click an option, it will open another screen so how can I do that?