1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
vesna_86 [32]
3 years ago
9

Describe an algorithm that produces the maximum, me- dian, mean, and minimum of a set of three integers. (The median of a set of

integers is the middle element in the list when these integers are listed in order of increasing size. The mean of a set of integers is the sum of the integers divided by the number of integers in the set.)
Mathematics
1 answer:
zheka24 [161]3 years ago
5 0

Answer

The mean of three numbers x1,x2,x3 can be obtained by a calculus. The first step of the algorithm is

1) mean(x1,x2,x3) = \frac{x1+x2+x3}{3}

In order to obtain the median, maximun and minumun of x1, x2 and x3, we can compare x1 and x2. The smaller of those numbers will be compared to x3 and, if x3 is even smaller, then x3 is the minimun, the other small number is the median, and the remaining number is the maximun. Otherwise, we compare x3 with the bigger number to find median and maximun. To summarize:

2) compare x1 with x2. The bigger of the two numbers will be called '<em>s</em>' (for  small) and the smaller will be called '<em>b</em>' (from big).

3) compare x3 with <em>s</em>. The smaller of this subset will be the minimun of the entire set of 3 elements.

4) Check if x3 is the minimun, in that case, <em>s </em>is the median, because <em>s</em> is between x3 and <em>b. </em>We also conclude that <em>b</em> is the maximun

5) if x3 in not the minimun, then compare it with <em>b.</em> The bigger element between the two of them will be the maximun of the set, and the smaller one will be the median.

I hope it helps you!

You might be interested in
Find the value of x in the picture below.
sveta [45]
The answer is c because
7 0
2 years ago
Triangle J is shown below. James drew a scaled version of Triangle J using a scale factor of 4 and labeled it
Novay_Z [31]

Answer:

The area of triangle K is 16 times greater than the area of triangle J

Step-by-step explanation:

we know that

If Triangle K is a scaled version of Triangle J

then

Triangle K and Triangle J are similar

If two triangles are similar, then the ratio of its areas is equal to the scale factor squared

Let

z -----> the scale factor

Ak ------> the area of triangle K

Aj -----> the area of triangle J

so

z^{2}=\frac{Ak}{Aj}

we have

z=4

substitute

4^{2}=\frac{Ak}{Aj}

16=\frac{Ak}{Aj}

Ak=16Aj

therefore

The area of triangle K is 16 times greater than the area of triangle J

4 0
2 years ago
Read 2 more answers
X(x-4)+y(y-10)=-29 x;y=?
zaharov [31]
X sqrd-4x+y sqrd-10= -29
y sqrd-10y = -29-X sqrd + 4X
y(y-10) = -29-X sqrd +4X
y = - 29 -X sqrd +4X ÷( y- 10)
6 0
2 years ago
Making an
Tems11 [23]
1. the combinations are 5 and 3 twice and 3 and 4 twice
5+3+5+3+3+4+3+4= 30 L

2. Trya can ride 12 , 18, 24,30 kilometres are the possible distance

3. lexi can put 4 ribbons and 2 photos on her bulletin that is 40 cm meters.
ribbons 4×4=16
bulletin 12×2=24
altogether 40 cm with nothing overlapping

4. don't know dollars and centd sorry I know pounds as I am British
7 0
3 years ago
Mystery number: The number is less than 190000 and greater than 180000.
Kipish [7]
The answer to it is    
180, 000 <n> 190, 000 
180,000 + 2000 = n = 5000-187, 000 
182,000 = n = 182, 000   
Or,  
 180, 000 <n> 190,000                     
 n + 5000= 187, 000                           n – 2000 = 180, 000 
 n= 187, 000- 5000                             n = 180, 000 + 2000 
 n= 182, 000                                       n= 182, 000 
6 0
3 years ago
Other questions:
  • A car traveling 281 miles 4 hours and 40 minutes what was the average speed of the car in miles per hours
    6·1 answer
  • 4 3/5 -2 1/3 what is the correct answer?
    15·2 answers
  • 5 divied by 5/6 please let me know
    12·2 answers
  • In the figure. What is the value of x? Also it cropped out the last answer choice which is 90.
    6·1 answer
  • HELP ME PLS IT IS TIMED
    14·1 answer
  • ANSWER ALL FOUR FOR BRAINLIEST
    6·1 answer
  • Last week, it rained g inches. This week, the amount of rain decreased by 5%. Which expressions represent the amount of rain tha
    13·1 answer
  • I need help with this
    15·1 answer
  • Solve x + 7 &gt; 15 or 2x - 1 &lt; 3.
    15·2 answers
  • Geometry PLEASE HELP<br><br> I’m right? Yes or no?
    14·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!