Skip to content

Commit 4e9b21e

Browse files
committed
added the docstrings in the functions
1 parent d62ebf7 commit 4e9b21e

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

strings/frequency_finder.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,9 @@
3636

3737

3838
def get_letter_count(message: str) -> dict[str, int]:
39+
'''get_letter_count() is a function that takes message as parameter which is
40+
supposed to be the string. and it returns a dictionary where string is a key
41+
and integer is a value.'''
3942
letter_count = dict.fromkeys(string.ascii_uppercase, 0)
4043
for letter in message.upper():
4144
if letter in LETTERS:
@@ -45,6 +48,7 @@ def get_letter_count(message: str) -> dict[str, int]:
4548

4649

4750
def get_item_at_index_zero(x: tuple) -> str:
51+
'''It takes x as parameter which is tuple and returns a string.'''
4852
return x[0]
4953

5054

0 commit comments

Comments
 (0)