SHARE
TWEET

Untitled

a guest Apr 2nd, 2019 83 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. text = '''The Zen of Python, by Tim Peters
  2. Beautiful is better than ugly.
  3. Explicit is better than implicit.
  4. Simple is better than complex.
  5. Complex is better than complicated.
  6. Flat is better than nested.
  7. Sparse is better than dense.
  8. Readability counts.
  9. Special cases aren't special enough to break the rules.
  10. Although practicality beats purity.
  11. Errors should never pass silently.
  12. Unless explicitly silenced.
  13. In the face of ambiguity, refuse the temptation to guess.
  14. There should be one-- and preferably only one --obvious way to do it.
  15. Although that way may not be obvious at first unless you're Dutch.
  16. Now is better than never.
  17. Although never is often better than *right* now.
  18. If the implementation is hard to explain, it's a bad idea.
  19. If the implementation is easy to explain, it may be a good idea.
  20. Namespaces are one honking great idea -- let's do more of those!'''
  21. text = text + 'davidovich336@gmail.com'
  22.  
  23. #the count of all symbols in <text>
  24. print(len(text))
  25.  
  26. #the count of all symbols in <text>
  27. text_new = text.lower()
  28. count_vowels = 0
  29. for x in text_new:
  30.     if x in 'eyuioa':
  31.         count_vowels += 1
  32. print(count_vowels)
  33.  
  34.  #each 18th symbol of the string
  35. spisok = list(text)
  36. number = 0
  37. for x in range (17, len(text), 18):
  38.     number += 18
  39.     if spisok[x] in 'QWERTYUIOPASDFGHJKLZXCVBNM':
  40.         print(number, spisok[x].lower(), sep="")
  41.     elif spisok[x] in 'qwertyuiopasdfghjklzxcvbnm':
  42.         print(number, spisok[x].upper(), sep="")
  43.     else:
  44.        print(number, spisok[x],  sep="")
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top