Created
April 21, 2020 13:05
-
-
Save Celia-code/70cccce60b97c92d9b1846170830d78b to your computer and use it in GitHub Desktop.
字符串
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
text = 'hello py hi py' | |
print(text.count('py')) | |
# 打印出2 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment