Counting of 1's 2's 3's 4's in T20 game
In a T20 game, AB Devillars have faces 10 balls continuously. In these 10 balls, he scores many 6âs, 4âs, 1âs and 2âs. Two cricket analysts, are trying to find out the following things: finding the average score rate per ball and Number of 1âs, 2âs, 3's, 4âs and 6âs he scored in these 10 balls Design one function, which will help these cricket analysts to find this statistics. Input Format 10 integer numbers (Run scores in each ball) Constraints He didnât score any 5 in these 10 balls those he have faced He didnât get same score in consecutive balls. If constraints didnât matched display âWrong Inputâ without quotes. Output Format out put is Number of 1âs, 2âs, 4âs and 6âs and average run per ball in given format Sample Input 0 2 4 6 1 0 4 6 1 2 6 Sample Output 0 1's=2 2's=2 3's=0 4's=2 6's=3 0's=1 Average Score Rate=3.2 per ball Explanation 0 Average Score Rate is Total Run/Total balls