<prompt> Kujenga programu Python kugundua idadi ya vokali na konsonanti katika kamba  <response>: Here is a simple python program to detect the number of vowels and consonants in a given string:pythondef count_vowels_consonantsstring: Initialize a variable to count vowels vowel_count 0 Initialize a variable to count consonants consonant_count 0 Create a list of vowels vowels a, e, i, o, u Convert the string to lowercase if it has uppercase letters string string.lower Iterate through each character in the string for char in string: If the character is a vowel, increase the vowel count if char in vowels: vowel_count 1 If the character is not a vowel, increase the consonant count else: consonant_count 1 Return the vowel count and consonant count return vowel_count, consonant_count Run the function with a sample stringsample_string This is an examplevowel_count, consonant_count count_vowels_consonantssample_string Print the resultsprintfNumber of vowels in the string: vowel_countprintfNumber of consonants in the string: consonant_count 