... Python Language 教程 · 數數 · 計算字串str.count() 中子字串的出現次數 ... 1 astring.count('is') # Out: 2 astring.count('text') # Out: 1.
確定! 回上一頁