The translit module¶
-
translit.
count_letters
(text)¶ Count number of different letters in text and print frequency table (case insensitive)
-
translit.
count_patterns
(patterns)¶ Count all repetitions of the same string in the list of strings patterns. The result is printed in alphabetical order
-
translit.
count_word2
(text)¶ Count number of different two letter words in text and print frequency table this assumes the encoded message has preserved punctuation and spaces (case insensitive)
-
translit.
count_word3
(text)¶ Count number of different three letter words in text and print frequency table this assumes the encoded message has preserved punctuation and spaces (case insensitive)
-
translit.
translit
(text, code)¶ Substitution cypher
- Inputs:
- text - to cypher (or uncypher)
- assumed UPPERCASE
- code - the substitition for the alphabet. All substituted letters
- are assumed lowercase.
- Outputs:
- a string with the substituted text
example:
print translit("HELLO WORLD","zyxwvutsrqponmlkjihgfedcba") svool dliow