To count the number of occurrences of a sub-string in a string, use String.count() method on the main string with sub-string passed as argument.
確定! 回上一頁