劉洸瑋Python字串string方法methods

txt = "劉洸瑋 love 蘋果, 蘋果是我 are my favorite 水果蘋果" print(txt.count("蘋果")) print('先練習內建函數len',len(txt)) print('find',txt.find("蘋果")) print(''rfind',txt.rfind("蘋果"))

留言

張貼留言

這個網誌中的熱門文章

劉洸瑋google co-laboratory機器學習

劉洸瑋python寫入write迴圈範圍range