Rexx - find() 方法
此方法用于搜索一个字符串在另一个字符串中第一次出现的位置。
语法
find(string, phrase)
参数
string − 需要查找的字符串值。
phrase − 这是需要在字符串中搜索的值。
返回值
该方法返回字符串中短语的第一个单词的单词编号。
示例
/* 主程序 */
options arexx_bifs
say find(' Hello World ','World')
当我们运行上面的程序时,我们将得到以下结果。
输出
2

