It’s time to find out which player is consistent in cricket. You need to calculate the average of a
player based on his score. Player average is defined as total runs scored by a player in N matches
divided by the number of matches in which he gets out. If the answer is too large you need to print
“-1” (without inverted comma’s).
The first line of the input contains T denoting number of test cases.
First line of each test case contains N denoting number of matches.
Next N line contains an integer denoting the number of runs scored by player in that match followed by a string which can be "out" or "notout" depending on whetherthe player is out or not-out in the match.
You need to print average of the player. If answer is not an integer take ceil and print your answer.
0<=Runs scored in a single match<=300
If you have purchased any course from GeeksforGeeks then please ask your doubt on course discussion forum. You will get quick replies from GFG Moderators there.