Skip to content

Files

Latest commit

46c6185 · Feb 24, 2023

History

History

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
Feb 24, 2023
Feb 24, 2023

Letter Count

Write a function that takes a string and a letter as its arguments and returns the count of the letter in the string.


Sample input:

hello, how are you?
o

Sample output:

3

Explanation: The letter o appears 3 times in the given text.


The given code takes the string and letter from input and passes them to the letter_count() function. Define the function, so that the given code works as expected.