summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--python.html.markdown3
1 files changed, 3 insertions, 0 deletions
diff --git a/python.html.markdown b/python.html.markdown
index 28b0a7ae..fa604455 100644
--- a/python.html.markdown
+++ b/python.html.markdown
@@ -126,6 +126,9 @@ not False # => True
# A string can be treated like a list of characters
"This is a string"[0] # => 'T'
+# You can find the length of a string
+len("This is a string") # => 16
+
#String formatting with %
#Even though the % string operator will be deprecated on Python 3.1 and removed
#later at some time, it may still be good to know how it works.