結果 : java count number of substrings in a string