human
Print the most occurring character in an array of strings | Function to print the most occurring character.
Creating a hash of size 26.
For loop to iterate through every string of the array.
For loop to iterate through every character of the string.
Incrementing the count of the character in the hash.
Finding the character with the maximum count.
Driver code.
Declaring Vector of String type"
Solution in Python:
 Can you provide a code to print the most occurring character in an array of strings and the other steps required?
assistant
#Here is code to print the most occurring character in an array of strings and the other steps required.
 def findMostOccurringChar ( string ) :
	hash = [ 0 ] * 26 ;
	for i in range ( len ( string ) ) :
		for j in range ( len ( string [ i ] ) ) :
			hash [ ord ( string [ i ] [ j ] ) - ord ( ' a ' ) ] += 1 ;
	max = 0 ;
	for i in range ( 26 ) :
		max = i if hash [ i ] > hash [ max ] else max ;
	print ( ( chr ) ( max + 97 ) ) ;
if __name__ == " _ _ main _ _ " :
	string = [ ] ;
	string . append ( " animal " ) ;
	string . append ( " zebra " ) ;
	string . append ( " lion " ) ;
	string . append ( " giraffe " ) ;
	findMostOccurringChar ( string ) ;