coding for given question

coding for given question

Board of Control for Cricket in India wants to award all the best bowlers, based on their performances in a year. A Bowler is called the Best, if the average wickets taken by him during the year is 5 and above. The number of matches played is calculated by the number of digits provided against a player. Assume that no bowler has taken 10 wickets in a match. BCCI has assigned you task to write a program that calculates the count of best bowlers among the given lot. Input/Output Specs Input Specs Your program must read one arguments ( string1) where string1 is a string[] that provides you the input details. String1 is a string array that provides you each player details.

Sample Input: String1 = {â??2210011â??, â??1115422363â??, â??4645637468â??, â??023013â??, â??1323402022â??} Here array represents the number of player information that is provided to you. Considering the 5 players as V. Kumar, R. Ashwin, P. Ojha, V. Aaron, U. Yadav Vinay Kumar has played 7 matches and the performances are 2,2,1,0,0,1,1. The average wickets taken in those 7 matches are 1 wicket per match. Since the criteria are 5, his is not included in the Best Bowlers list. For Ashwin, the number of matches played is 10 and his performances are 1,1,1,5,4,2,2,3,6,3. The average wickets taken per match are 2.8. Since the critera are 5, his is also not included in the list. Similarly for P. Ojha, average wickets taken based on the given details are 5.3. As he fits the criteria of 5 and above, he is included in the Best Bowlers list. For V. Aaron, he doesnâ??t fit the criteria because the average wickets taken by him are only 1.5 For U. Yadav, he also doesnâ??t fit the criteria because the average wickets taken by him are only 1.9 So the total number bowlers who satisfied the criteria for Best Bowler is only one (P.Ojha). So , The output is 1

Coding Specs

class CricketBoard
{
//method to find the best bowler.
public static int findBestBowlers(String [] string1)
{
int output1 = 0;
// Your code here
return output1;
}
public static void main(String [] args)
{
String [] string1 = new String[5];
//Code here for user input in string1
int result = findBestBowlers( string1);
System.out.println(â??No of Best Bowlers : â??+result);
}
}
View Answers









Related Tutorials/Questions & Answers:
coding for given question
coding for given question  Board of Control for Cricket in India... of best bowlers among the given lot. Input/Output Specs Input Specs Your program.... Ojha, average wickets taken based on the given details are 5.3. As he fits
please help me in coding this given program
please help me in coding this given program  consider the below series: 1,2,1,3,2,5,3,7,5,11,8,13,13,17,..... this series is a mixture of 2 series-all the odd terms in this series from a fibonacci series and all the even terms
Advertisements
please help me in coding this given program
please help me in coding this given program  consider the below series: 1,2,1,3,2,5,3,7,5,11,8,13,13,17,..... this series is a mixture of 2 series-all the odd terms in this series from a fibonacci series and all the even terms
how i want to create a coding by this question?
how i want to create a coding by this question?  Design and write a class named Person and its two subclasses named Student and Employee. Make Lecturer and Admin subclasses of Employee. A person has a name, address, phone number
hi... pls give me the example of java coding fo following question
hi... pls give me the example of java coding fo following question  example java coding that reads in the radius and length of cylinder and computes volume. formula: Area = radius * radius * PI Volume = area * length
hi.. please give me a java coding for the following question
hi.. please give me a java coding for the following question  Write a program that prompts the user to enter the number of students and each studentâ??s name and score, and finally displays the name of the students
hi.. please give me a java coding for the following question
hi.. please give me a java coding for the following question  Write a program that reads in investment amount, annual interest rate, and number of years, and displays the future investment value using the following formula
hi.. please give me a java coding for the following question
hi.. please give me a java coding for the following question  Write a program that displays the following table (note that 1 mile is 1.609 kilometers). Miles Kilometers
hi.. please give me a java coding for the following question
hi.. please give me a java coding for the following question  Suppose that the tuition for a university is RM10,000 this year and increases 5% every year. Write a program that computes the tuition in ten years and the total cost
hi.. please give me a java coding for the following question
hi.. please give me a java coding for the following question  Write a function called ChangeToNext that take in an uppercase character parameter ch. The function returns the next uppercase character if ch is between 'A' and 'Y
hi... pls give me the example of java coding for following question
hi... pls give me the example of java coding for following question   Write a program that computes loan payments. The loan can be a car loan, a student loan, or a home mortgage loan. The program lets the user enter the interest
hi... pls give me the example of java coding fo following question
hi... pls give me the example of java coding fo following question  Write a java program that reads the following information and prints a payroll statement: Employeeâ??s name (e.g: Sam) Number of hours worked in a week (e.g: 10
hi.. please give me a java coding for the following question
hi.. please give me a java coding for the following question  Body Mass Index(BMI) is a measure of health on weight. It can be calculated by taking your weight in kilograms and dividing by the square of your height in meters
hi.. please give me a java coding for the following question
hi.. please give me a java coding for the following question  Write a class that contains the following two methods: /* converts from inches to centimeters */ Public static double inchToCentimeter(double in) /* converts from
coding
coding  I need the logout coding. can you please help me.   Please visit the following links: http://www.roseindia.net/quickguide/tomcat/Logout.shtml http://www.roseindia.net/jsp/loginstatus.shtml
question
question   sir plz tell me what should i give in title box. just i want java program for the question typed in this area
question
question   sir plz tell me what should i give in title box. just i want java program for the question typed in this area
Question
Question   When there is an exception in my program how java runtime system handles
question
question  dear sir/madam my question is how to compare two text format in java..we are java beginners..so we need the complete source code for above mentioned question...we have to compare each and every word
question
question  please give me the relevant modules and details to start java coding for "Deriving Concept-based User Profiles from Search Engine Logs" it's very urgent
question
question  Dear sir i had some typing mistake at previous question so its my humble request to let me know the steps to start the tomcat6 under the tomcat directory
question
question  Gud morning sir, I have asked u some question regarding jsp in saturaday for that i didnot find any answere in which u send me the some of the links.U have asked me the specify some details. There is a entity name
Question?
Question?  My question is how to: Add a menu bar to the program with a File menu. In the File menu, add a submenu (JMenuItem) called About. When the user clicks on the About menu item, display a JOptionPane message dialog
Question
Question  which url address should be given in web.xml
Question
Question  Sir, give me a java program to count the number of tokens , given a string and a seperator
Question
,the questions like find out the result of given code(to find out result from the given code). please also send me the answers with the questions
Question
find out the result of given code(to find out result from the given code
Question
of given code(to find out result from the given code). please also send me
question
question  Good after noon Sir, Please send me the code of the problem given below.it's urgent code to display employees on absent and manager can approve,and send a notification message to an employee.using JPanel+mysql+Java
question
question  i have a project for search engine .i have a starting trouble , from where do i start project ,please help me.when i am given a key word to search ,which must return title,summary and url and i want to capture
question
question  good morning, iam using the code given below in mysql,but that retuned zero rows selected select * from leavetable where leave_type in ('Sick Leave(SL)','Half Day Leave(HL)','Leave(L)') and currentdate='curdate
question
question  good morning, iam using the code given below in mysql,but that retuned zero rows selected select * from leavetable where leave_type in ('Sick Leave(SL)','Half Day Leave(HL)','Leave(L)') and currentdate='curdate
question
question  Dear Sir , could you please send me programmatic type ( to find out result from the given Java code ) Core Java interview questions It's very urgent I have interviews , please send me as soon as possible.   
coding for project
coding for project  hai how to write jsp coding for project smart accessories ...... that s to navigate to another page when you click on a tag
program coding
program coding  how to rearrange the array a[1]. . a[n] even elements and odd elements? please give the example coding program.please provide the coding for this problem
Java Coding
Java Coding  Hello, Can u please tel me how to improve my coding techniques.I am feeling difficulty with coding but I am perfect with my theory part
coding for chart
coding for chart  I want to convert a character into binary then convert it into its diagram in form of digital electrical signals.How can I do java coding for this diagram
coding of button
coding of button  What is code of fetching the value of button in a textbox using javascript
program coding
program coding  how to rearrange the array a[1]. . a[n] even elements and odd elements? please give the example coding program
coding C
coding C  Write a program for a GENERAL NUMBER CONVERTERS which include binary, decimal, octa and hexadecimal. You need to write the program using C language
coding for login page
coding for login page  coding for login page
coding for anchor tags
coding for anchor tags  coding for anchor tags
coding for anchor tags
coding for anchor tags  coding for anchor tags
coding for anchor tags
coding for anchor tags  coding for anchor tags
coding for anchor tags
coding for anchor tags  coding for anchor tags
coding for online reservation
coding for online reservation  coding for online reservation
coding for updating profile
coding for updating profile  coding for updating profile
coding for forgot password
coding for forgot password  coding for forgot password
coding for update profile
coding for update profile  coding for update profile
coding for deleting file
coding for deleting file  coding for deleting file

Ads