Answers
please rate - thanks
public class averagearray
{public static void main(String args[])
{int num[]={42,32,83,82,93,67,34,93,82,};
System.out.println("average: " + doAverage(num,num.length));
}
public static double doAverage(int a[], int n)
{int i,sum=0;
for(i=0;i<n;i++)
sum+=a[i];
return sum/(double)n;
}
}
Similar Solved Questions
1 answer
Question 6 Not yet answered Marked out of 8.00 P Flag question Two most important mode...
Question 6 Not yet answered Marked out of 8.00 P Flag question Two most important mode of free-radical termination is shown below. Which one is which? PH BITED. bon bon con con Select one or more: O A. (I) is termination by disproportionation and (II) is termination by coupling O B. (l) is terminati...
1 answer
Leur that repest a Post ve integer as pipit te the number is even, suide it...
Leur that repest a Post ve integer as pipit te the number is even, suide it by 2 tt not, mutip the wmber by 3 and then add t Repaat ts poces wth the resuling number and tomtne rependhng onil the 1 Heached the 土 ls reached, e program should display 丬he number of iterations repind 40each...
1 answer
5. Consider a Hydrogen atom with radius R = 5.29x10m. current loop. If Treat the orbiting...
5. Consider a Hydrogen atom with radius R = 5.29x10m. current loop. If Treat the orbiting electron as a this electron-proton system is placed in a magnetic field of 0.400T which is perpendicular to the magnetic moment of the loop, what is the torque ? (me = 9.11x10-31 kg 191- 1.60*10-19 C)...
1 answer
A 15-W compact fluorescent light bulb is used in a lamp plugged into a 120-V wall...
A 15-W compact fluorescent light bulb is used in a lamp plugged into a 120-V wall socket. You can assume the lamp itself has zero resistance. Find (a) the resistance of the light bulb, (b) the maximum current through the bulb, and (c) the maximum power used by the light bulb. Also, if the frequency ...
1 answer
What linear equation will determine the length, given the area of a rectangle is 48 sq ft and the width is 6ft?
What linear equation will determine the length, given the area of a rectangle is 48 sq ft and the width is 6ft?...
1 answer
(Only Part 2) Part 1 3. There are two individuals looking to rent apartments in a...
(Only Part 2) Part 1 3. There are two individuals looking to rent apartments in a neighborhood-consumer His willing to pay $5,000 as monthly rent and consumer L is only willing to pay $3,000 monthly rent. The valuation of the rental for each consumer is given below: Consumer Value of Apartment to Co...
1 answer
Directions: Use the definitions given to complete the crossword pule. DOWN 2 Complete suppression of urine...
Directions: Use the definitions given to complete the crossword pule. DOWN 2 Complete suppression of urine ACROSS 1 External opening of the urethra 6 Using artificial kidney machine to formed by kidneys 3 Term for a stone formed within an organ 4 Difficulty initiating flow of urine 5 Urinaryinabilit...
1 answer
Use the polar form of the complex number 5 i to find a value in Cartesian...
Use the polar form of the complex number 5 i to find a value in Cartesian form, z = x+iy. Enter the exact answer. Z= 0+iv 5 Edit...
1 answer
How to solve to get answer 0.71125? Questions 12 and 13 refer to the following setup....
How to solve to get answer 0.71125? Questions 12 and 13 refer to the following setup. Consider two screening tests for prostate cancer, the Digital Rectal Exam (DRE) and the Prostate Specific Antigen (PSA) test. Assume the DRE test has a 50% false-positive rate and a 45% false-negative rate, while t...
1 answer
Hello, it is just nutrition homework. what information did you need? alculi O Brief Shockt New...
hello, it is just nutrition homework. what information did you need? alculi O Brief Shockt New i W Edmor Can't https://edcc.instructure.com/courses/1811746742/A250936/take bedcci O QL X Newt Shock 4 Promo + V Question 3 2 pts Match the abbreviation or term with its definition RDA Choosel unlike ...
1 answer
Consider the following ANOVA summary table: ANOVA Summary Table SS df MS Source F 9 7.3...
Consider the following ANOVA summary table: ANOVA Summary Table SS df MS Source F 9 7.3 Group (Between) Error (Within) Total 2400 30 The researcher was comparing 9 groups and found there were no significant differences between the groups. o The researcher was comparing 8 groups and found there were ...
1 answer
Vandalay Industries manufactures two products: toasters and blenders. The annual production and sales of toasters is...
Vandalay Industries manufactures two products: toasters and blenders. The annual production and sales of toasters is 2,100 units, while 1,600 units of blenders are produced and sold. The company has traditionally used direct labor hours to allocate its overhead to products. Toas...
1 answer
3. For a reservoir whose pore-wolume compressibiliy is 1Tx10 psi, and where overburden pressure and pore...
3. For a reservoir whose pore-wolume compressibiliy is 1Tx10 psi, and where overburden pressure and pore pressure increase by 1 psi and 0.5 psi, respectively, per foot of depth, show that the porosity decreases by 1%(00,-0.99) for every 1000 feet increase in depth....
1 answer
8. Name three biosignals, their normal ranges in humans, a sensor that could detect each signal,...
8. Name three biosignals, their normal ranges in humans, a sensor that could detect each signal, and a cisease state that causes the signal to fall outsice the normal range....
1 answer
How do you solve #-9\cdot 17^ { - 4n - 8} - 4= - 40#?
How do you solve #-9\cdot 17^ { - 4n - 8} - 4= - 40#?...
1 answer
B 106° 120 100 feet feet 60° 599 C A 1350 106 86 feet feet The...
B 106° 120 100 feet feet 60° 599 C A 1350 106 86 feet feet The table below shows the field data for closed traverse ABCD, if the coordinates of A (0, 0). Azimuth for AB is 56°. Compute the coordinates for all other stations. a. Fill up the followings: Stations Observed Azimuth Length EN ...