IndexOf

搜索列表中第一次出现的值。

int IndexOf(
    item     // 搜索值
   );

参数

item

[in]  已搜索的值。

返回值

返回找到的第一个元素的索引。如果该值未找到,返回-1。