Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- def comptage():
- alpha = {chr(i + 64) for i in range(1, 27)}
- alpha = str(alpha)
- alphabet = alpha.lower()
- phrase = "Il fait beau ce matin a Tours"
- phrase = phrase.replace(" ", "")
- phrasE = phrase.lower()
- dictio = {}
- for elem in alphabet:
- if (phrasE.count(elem)):
- dictio[elem] = phrasE.count(elem)
- print(dictio)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement