Index and last index a pattern : index « String « Ruby. ... The index method returns the index location of a matching substring. 2. line[line.index("k")].
確定! 回上一頁