Guest User

Untitled

a guest
May 22nd, 2018
85
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.19 KB | None | 0 0
  1. import re
  2. text = re.sub('[^a-z]', '', 'HElow23orld!')
  3. print(text) # 'loworld'
  4. print(len(text)) # 7
  5.  
  6. import string
  7. print(len([c for c in 'HElow23orld!' if c in string.ascii_lowercase]))
Add Comment
Please, Sign In to add comment