Skip to content
Prev 361013 / 398506 Next

Grep command

j <- grep( paste0( some, collapse="|") , all ); j; all[j]
#----------
[1] 1 3 6
[1] "ants" "cats" "fox"