我有一组像这样的字符串
[[1]] [1] "The quick brown fox jumped over the sleeping lazy dog" [2] "The fox quickly turned around" [3] "The sun rises every day" [4] "Be quick on your feet"
我想返回一个包含子字符串的所有字符串位置的向量"快速"
结果应为
pos [1] 1 4
我试过了
pmatch("quick", x, nomatch = NA_integer_, duplicates.ok = TRUE)
但返回NA值。