- Java Program To Calculate Mean Median Models
- Java Program To Calculate Mean Median Mode And Range
- Mean Median Mode Formula
Greenhorn
Apr 26, 2018 Java program to calculate mean of given numbers; Java program to calculate Body Mass Index (BMI). Java program to calculate mode in Java. Java Programming Java8 Object Oriented Programming. In statistics math, a mode is a value that occurs the highest numbers of time. For Example, assume a set of values 3, 5, 2, 7, 3. Specifically, we want to be able to determine the mean, median, and mode of the array of integers. Mean is the arithmetic average of a series of numbers. It is found by summing all of the numbers and then dividing by the number of elements (numbers) in the series. Median is the middle number (of a.
Write a java program to calculate median of the array. Write a java program to calculate median of the array. Write a program to accept an int array as input, and calculate the median of the same. Median Calculation Procedure: Sort the sequence of numbers. The total number count is odd, Median. This java programming code is used to find the mean, median, mode. You can select the whole java code by clicking the select option and can use it. When you click text, the code will be changed to text format. This java program code will be opened in a new pop up window once you click pop-up from the right corner.
posted 16 years agook heres the thing i am trying to create a program (in java of course) that will find the mode of ten seperately inputted numbers, no arrays, i hate them and i know theres plent of ways to get around them, anywho im not having any luck, help me please
Ranch Hand
posted 16 years ago
Sheriff
posted 16 years agoDefintion of 'mode' --> The mode of a set of data is the value in the set that occurs most often.
Chase-
So, you're trying to calculate the mode of a set of data, and you don't want to use an array. What have you tried? Where are you having trouble? What part are you not able to 'get'? We'd love to help you, but we're not going to do the work for you. If you'd like to post your code and specifically explain what the problem is -- we'd be more than happy to help you de-bug the problem and maybe even offer some alternative solutions. How's that sound?
In the mean time, Im moving this to Java In General (Beginner) forum, where I think its more appropriate. Good luck!
Chase-
So, you're trying to calculate the mode of a set of data, and you don't want to use an array. What have you tried? Where are you having trouble? What part are you not able to 'get'? We'd love to help you, but we're not going to do the work for you. If you'd like to post your code and specifically explain what the problem is -- we'd be more than happy to help you de-bug the problem and maybe even offer some alternative solutions. How's that sound?
In the mean time, Im moving this to Java In General (Beginner) forum, where I think its more appropriate. Good luck!
- Jess
Blog:KnitClimbJava | Twitter: jsant | Ravelry: wingedsheep
Blog:KnitClimbJava | Twitter: jsant | Ravelry: wingedsheep
(instanceof Sidekick)
posted 16 years ago![Java Program To Calculate Mean Median Mode Java Program To Calculate Mean Median Mode](https://ecdn.teacherspayteachers.com/thumbitem/Mean-Median-Mode-Range-FREEBIE-1406398210/original-593996-4.jpg)
Try to think up a solution in relatively plain english. Maybe
Now you have a handful of small problems:
How do you go through your input set?
How do you keep a counter for each number?
Where do you remember the highest counter so far?
Where do you remember the number that got the highest count?
And if you really want to blow your instructor away, show em this: http://www.cs.utexas.edu/users/moore/best-ideas/mjrty/index.html (Shucks, that only works if there is a MAJORITY number, I think)
Have fun! Don't take my word for that plain language algorithm. See if you can do better!
Now you have a handful of small problems:
How do you go through your input set?
How do you keep a counter for each number?
Where do you remember the highest counter so far?
Where do you remember the number that got the highest count?
And if you really want to blow your instructor away, show em this: http://www.cs.utexas.edu/users/moore/best-ideas/mjrty/index.html (Shucks, that only works if there is a MAJORITY number, I think)
Have fun! Don't take my word for that plain language algorithm. See if you can do better!
Java Program To Calculate Mean Median Models
A good question is never answered. It is not a bolt to be tightened into place but a seed to be planted and to bear more seed toward the hope of greening the landscape of the idea. John Ciardi
Greenhorn
posted 16 years agook there is nothing wrong with the code, but i just have no clue of the formula i am sposed to actually use, that is my only problem, and if you cant help that is fine
Greenhorn
posted 16 years agoim sitting right next to him and here is the problem that he is having he needs to write a program to calculate the code he has the code wrote out he just needs help figuring out the math like should he use a switch statement but the only problem is the user can enter any range of numbers
lowercase baba
posted 16 years agoWhat code do you have written out? What does it do/not do? What part are you having trouble with exactly?
People here love to help, but i'm not sure what your problem is. just telling us 'it doesn't work' doesn't do any good. If the code isn't too long, you can use the code tags and post what you written so far, and someone will probably give you some suggestions.
People here love to help, but i'm not sure what your problem is. just telling us 'it doesn't work' doesn't do any good. If the code isn't too long, you can use the code tags and post what you written so far, and someone will probably give you some suggestions.
There are only two hard things in computer science: cache invalidation, naming things, and off-by-one errors
Greenhorn
posted 16 years agook he has the input wrote out and what he is having problems with is the math cause he doesnt really know what to do like what system he should use or what so is there anyone that can help him figure out the math part of the program of like what he should do cause the user can enter any number
lowercase baba
posted 16 years agoi don't know what you mean by 'what system should he use'.
there really isn't a lot of math involved in figuring out the mode. you need to scan all the input values, and count how many times each unique value appears. for example, if the 10 input numbers are:
5,8,2,3,6,5,1,8,0,8
since 8 occurs more than any other number, the mode is 8. the only math involved is simple addition and doing some comparisons (i.e. is one value greater than another).
when you say 'he has the input wrote', is he saving all 10 input numbers, so they can all be accessed later? or is he incrementing a counter for each as it is input?
again, it's much easier to help if you POST THE CODE. there are probably hundreds of ways to do this, but without knowing what path you've started, everybody is just making blind guesses on how to help you get further along.
[ May 11, 2004: Message edited by: fred rosenberger ]
there really isn't a lot of math involved in figuring out the mode. you need to scan all the input values, and count how many times each unique value appears. for example, if the 10 input numbers are:
5,8,2,3,6,5,1,8,0,8
since 8 occurs more than any other number, the mode is 8. the only math involved is simple addition and doing some comparisons (i.e. is one value greater than another).
when you say 'he has the input wrote', is he saving all 10 input numbers, so they can all be accessed later? or is he incrementing a counter for each as it is input?
again, it's much easier to help if you POST THE CODE. there are probably hundreds of ways to do this, but without knowing what path you've started, everybody is just making blind guesses on how to help you get further along.
[ May 11, 2004: Message edited by: fred rosenberger ]
There are only two hard things in computer science: cache invalidation, naming things, and off-by-one errors
Ranch Hand
posted 16 years agoStan James has already posted pseudocode for the algorithm you can use. Now all you need to do is change it into Java code.
If you still don't understand, please post the code you already have and what problems you've encountered in trying to implement the code. You should also try writing out an explanation, in your native language, of the steps you should take to find the answer. Perhaps it will help to do an example by hand. Then you can more easily see what steps are needed.
HTH
Layne
If you still don't understand, please post the code you already have and what problems you've encountered in trying to implement the code. You should also try writing out an explanation, in your native language, of the steps you should take to find the answer. Perhaps it will help to do an example by hand. Then you can more easily see what steps are needed.
HTH
Layne
Monday, March 18th, 2019
In this post, we will be discussing mean, median, mode concepts and their solved examples which is a frequently asked topic in XAT and SNAP examination. We will start our discussion with basic concepts of statistics followed by some examples that will help you get a better understanding of the concept. The short tricks to solve some particular questions are discussed during the solution of the question.
1. Mean, Median, Mode Concepts and Properties
Mean, median, and mode are three kinds of “averages”. There are many “averages” in statistics, but these are, the three most common, and are certainly the three you are most likely to encounter in your CAT exams, if the topic comes up at all.
The “mean” is the “average” you’re used to, where you add up all the numbers and then divide by the number of numbers.
The “median” is the “middle” value in the list of numbers. To find the median, your numbers have to be listed in numerical order from smallest to largest, so you may have to rewrite your list before you can find the median.
The “mode” is the value that occurs most often. If no number in the list is repeated, then there is no mode for the list.
The “range” of a list a numbers is just the difference between the largest and smallest values. Let us understand the concepts better by use of some examples.
The formula for the place to find the median is “([the number of data points] + 1) ÷ 2″, but we don’t have to use this formula. We can just count in from both ends of the list until you meet in the middle, if you prefer, especially if your list is short. The formula works when the number of terms in the series is odd. In case there are even number of numbers, median will be average of two middle numbers in the list.
MEAN VALUE: Mean value refers to the average of a set of values. The simplest way to find the mean is sum of all the values in the set divided by total number of values in the set.
Mean = Sum of all values/total number of values
Example 1: The set S = { 5,10,15,20,30}, Mean of set S = 5+10+15+20+30/5 = 80/5 = 16
Sometimes, the question includes frequency of the values. In that case, the formula changes to
Mean = ∑FiXi / ∑Fi ,
Where, Fi = frequency of the ith value of the distribution, Xi = ith value of the distribution
Example 2: For the given distribution, find the Mean
Xi | Fi |
1 | 3 |
2 | 5 |
3 | 8 |
4 | 4 |
∑Fi= 20 |
Solution: Mean = (1×3+2×5+3×8+4×4)/20 = 2.65
MEDIAN: Median signifies the central value or the middle value in a sorted list of numbers. To calculate median, the data has to be sorted in ascending or descending order.
Example 3: Find the median of the set = { 2,4,4,3,8,67,23 }
Solution: As we can see the list is not arranged in any order. The sorted list in ascending order = {2,3,4,4,8,23,67}. The list contains 7 terms, thus 4th term of the list will be the median, so the median is 4.
If the list contains ‘n’ terms (n is an odd number), the median will be the (n+1)/2 term.
In case the list consists of even number of terms, the median will be the average of nth and (n+1)th term.
Example 4: Find the median of the set = { 11,22,33,55,66,99 }
Solution: As we can see the list is already in ascending order and the list contains 6 terms, hence the average of the third and fourth term will be the median.
Median = (33+55)/2 = 44.
Example 5: Find the median of a series of all the even terms from 4 to 296.
Solution: The given sequence is 4,6,8,10,12,14….296. As we can see, the given sequence is an Arithmetic progression ( An arithmetic progression is a sequence of terms where any two consecutive terms differ by a constant difference). To find out the median, we need to know the number of terms. We will use the nth term of an arithmetic progression formula (an = a1 + (n-1)d) to calculate the number of terms. Then, depending on whether n is odd or even we can find out the media. The entire process will take up a lot of time.
Remember: If the given sequence is Arithmetic sequence, then
Java Program To Calculate Mean Median Mode And Range
Median = First term+Last term/2 = Mean
For this sequence, Median = 4+296/2 = 150.
MODE: For a given sequence, the value with the highest frequency is known as the mode.
Example 6: Find the mode of the Set = {1,3,3,6,9}
Solution: In the sequence, the value ‘1’ occurs maximum number of times, hence the mode is 1.
Remember: There can be more than one mode in a series. For example, in the set = {2,4,4,6,8,9,9}, both 4 and 9 are the Modes as their frequency of occurrence is more than other values.
RANGE: The range for any distribution is given by = Highest value – Lowest value.
STANDARD DEVIATION (S.D): Standard deviation signifies the deviation of the terms from the mean value of the distribution. It quantifies the amount of variation of a set of data values.
Example 7: Which of the following sequences have the highest S.D.
- 2,4,6,8
- 3,6,9,12
- 4,8,12,16
- 1,2,3,4
Solution: In the given four sequences, ‘a’ has a difference of 2 between any two consecutive terms, ‘b’ has a difference of 3, ‘c’ has a difference of 4 and ‘d’ has a difference of 1. As the number of terms in all the sequence are same and the sequences are sorted in ascending order, we can conclude that ‘c’ has maximum S.D. because it has maximum difference between any two terms. But, this might not always be the case. In question with different number of terms and varying differences between consecutive terms, we need to use the formula for S.D.
Online Coaching Course for CAT 2020
a) 900+ Videos covering entire CAT syllabus
b) 2 Live Classes (online) every week for doubt clarification
c) Study Material & PDFs for practice and understanding
d) 10 Mock Tests in the latest pattern
e) Previous Year Questions solved on video
b) 2 Live Classes (online) every week for doubt clarification
c) Study Material & PDFs for practice and understanding
d) 10 Mock Tests in the latest pattern
e) Previous Year Questions solved on video
Javascript on your browser is not enabled.
Standard Deviation = |
Where,
x̅ = mean value of distribution
x̅ = mean value of distribution
n = number of terms.
Let us calculate standard deviation for a simple sequence – { 1,3,3,3,5}
We will divide the entire process into five steps:
Step 1: Calculate the mean value
Mean = 1+3+3+3+5/5 = 3
Step 2: take the difference of all the terms from the mean value ( x – x̅)
1-3 = -2; 3-3 = 0; 3-3 = 0; 3-3=0; 5-3 = 2
Step 3: Square all these differences
(-2)2 = 4; 02 = 0; 02 = 0; 02 = 0; (2)2= 4
Step 4: Take the average of the squares in step 3
Average = 4+0+0+0+4/5 = 8/5
Step 5: Square root of the average is the Standard Deviation =
Standard deviation is denoted by greek letter ‘σ’
VARIANCE: It is defined as the average of the squared differences from the mean. In simple terms, to calculate the Variance, you need to square the S.D. or the quantity we got in step ‘4’ of S.D. calculation is variance.
Variance = σ2
WEIGHTED AVERAGE: The formula for weighted average is given by:
Where, Ni = number of values in ith group, Wi = average of the ith group
To understand weighted average, let us take two groups G1 (group of N1 rice packets) and G2 (group of N2 wheat packets), with number of items in G1 as N1 and number of items in G2 as N2. The average quantity of group 1 is W1 and the average quantity of group 2 is W2. When we combine both the groups the average quantity in each packet becomes the weighted average. Let us understand this concept with the help of an example.
Example 8: A shopkeeper has 50 cold drink bottles. Some of the bottles are 1-liter and some are 2-liter bottles. The average cold drink of the bottles is 1200 ml. Find the number of 2-liter bottles. (1 liter = 1000 ml)
Mean Median Mode Formula
Solution: We have two groups, one of 1-lit bottles and other one of 2-lit bottles. Let us say number of 2-lit bottles is N1 and number of 2-lit bottles is N2. We know that N1 + N2 = 50 as given the in question. The average of group 1 (W1) is 1000 ml as all the bottles are of equal quantity, i.e. 1000 ml. Similarly, the average of group 2 (W2) is 2000 ml. With the help of weighted average formula we can calculate N1 and N2. The weighted average here is 1200 ml. Let us put the values in the equation.
As N1 + N2 = 50, Replacing and solving for N1 we get, N1 = 40 and N2 = 10. Thus, the shopkeeper has 10 bottles of 2-lit.
Let us take few more examples from Mean / Median / Mode concepts:
Example 9: Find the mean, median, mode, and range for the following list of values: 13, 18, 13, 14, 13, 16, 14, 21, 13
Solution: The mean is the usual average, so we’ll add and then divide:
(13 + 18 + 13 + 14 + 13 + 16 + 14 + 21 + 13) ÷ 9 = 15
(13 + 18 + 13 + 14 + 13 + 16 + 14 + 21 + 13) ÷ 9 = 15
Note that the mean, in this case, isn’t a value from the original list. This is a common result. You should not assume that your mean will be one of your original numbers.
The median is the middle value, so first we’ll have to rewrite the list in numerical order:
13, 13, 13, 13, 14, 14, 16, 18, 21
There are nine numbers in the list, so the middle one will be the (9 + 1) ÷ 2 = 10 ÷ 2 = 5th number:
13, 13, 13, 13, 14, 14, 16, 18, 21
So the median is 14.
The mode is the number that is repeated more often than any other, so 13 is the mode, since 13 is being repeated 4 times.
The largest value in the list is 21, and the smallest is 13, so the range is 21 – 13 = 8.
Mean: 15 |median: 14 |mode: 13 |range: 8
Example 10: A sequence consists of 7 terms arranged in descending order. The mean value of the sequence is 70. If 30 is added to each term, and then each term is divided by 2 to get the new mean as ‘K’. Find the difference between K and the original mean.
Solution: Let us say the seven terms are a1, a2, a3, a4, a5, a6, a7. As the mean is 70,
a1 + a2 + a3 + a4 + a5 + a6 + a7 = 70×7 = 490
After adding 30 to each term, the new sum becomes,
(a1+30) + (a2+30) + (a3+30) + (a4+30) + (a5+30) + (a6+30) + (a7+30) = 70×7 + 30×7 = 700
The mean becomes 700/7 = 100.
After dividing each term by 2, the sum becomes,
New mean = 350/7 = 50
Difference between new mean and original mean = 70 – 50 = 20.
As you might have noticed in this example that the mean value is directly changed by any operation done on the values of the sequence.
Remember:
- If you add, subtract, multiply or divide all the values of the sequence by a number, say ‘k’, then you’ve to add, subtract, multiply or divide the original mean by ‘k’ to get the new value of the mean.
- If you add or subtract a number to all the values of the sequence, then the standard deviation has no effect but if you multiply or divide all the terms by a number ‘k’, multiply or divide the S.D. by |k|.
To understand the second point, let us take an example.
Example 11: A sequence consists of 9 terms. The standard deviation of the sequence is 50. If 10 is added to each term, and then each term is multiplied by -2. Find the new S.D.
Solution: As we have discussed, the S.D does not change when we add or subtract a number to the terms of the sequence. So after adding 10 to each term, S.D remains as 50. In the second operation, each term is multiplied by -2. When me multiply a constant to each term, we multiply the S.D by modulus of that number, thus the new S.D = 50 x |-2| = 50 x 2 = 100.
Example 12: Find the mean, median, mode, and range for the following list of values: 1, 2, 4, 7
Solution: The mean is the usual average:
(1 + 2 + 4 + 7) ÷ 4 = 14 ÷ 4 = 3.5
The median is the middle number. In this example, the numbers are already listed in numerical order, so we don’t have to rewrite the list. But there is no “middle” number, because there are even number of numbers. Because of this, the median of the list will be the mean (that is, the usual average) of the middle two values within the list. The middle two numbers are 2 and 4, so:
(2 + 4) ÷ 2 = 6 ÷ 2 = 3
So the median of this list is 3, a value that isn’t in the list at all.
The mode is the number that is repeated most often, but all the numbers in this list appear only once, so there is no mode.
The largest value in the list is 7, the smallest is 1, and their difference is 6, so the range is 6.
Mean: 3.5 | median: 3 |mode: none |range: 6
Example 13: A student has gotten the following grades on his tests: 87, 95, 76, and 88. He wants an 85 or better overall. What is the minimum grade he must get on the last test in order to achieve that average?
Solution: The minimum grade is what we need to find. To find the average of all his grades (the known ones, plus the unknown one), we have to add up all the grades, and then divide by the number of grades. Since I don’t have a score for the last test yet, I’ll use a variable to stand for this unknown value: “x“. Then computation to find the desired average is:
(87 + 95 + 76 + 88 + x) ÷ 5 = 85
Multiplying through by 5 and simplifying, I get:
87 + 95 + 76 + 88 + x = 425
346 + x = 425
x = 79
He needs to get at least a 79 on the last test.
Example 14: In a sequence of 25 terms, can 20 terms be below the average? Can 20 terms be between median and average?
Solution: Yes. We can have 24 zeroes and 1500 as the 25 numbers. In this case, there are 24 numbers below the average number.
No, in a sequence of 25 numbers, 12 will be greater than or equal to the median and 12 will be lesser than or equal to the median. We cannot have 20 terms in between the average and median
Correct Answer: 24 numbers below the average, 0 numbers between the average and median
Correct Answer: 24 numbers below the average, 0 numbers between the average and median
Example 15: The median of n distinct numbers is greater than the average, does this mean that there are more terms above the average than below it?
Solution: If there are odd number of terms, say, 2n + 1, then the median is the middle term. And if average is lesser than the middle term, there will at least be n + 1 terms greater than the average. So, there will
Be more terms above the average than below it.
However, this need not be the case when there are an even number of terms. When there are 2n distinct terms, n of them will be greater than the median and n will be lesser than the median.
Also, the average of these two terms can be such that there are n terms above the average and n below it.
For instance, if the numbers are 0, 1, 7, 7.5. The median is 4, average is 3.875. Average is less than the median. And there are more 2 numbers above the average and 2 below the average.
So, answer is it is not necessary that if median is greater than average, there will be more terms above average than below it, specifically in the scenario that there are even number of terms.
For instance, if the numbers are 0, 1, 7, 7.5. The median is 4, average is 3.875. Average is less than the median. And there are more 2 numbers above the average and 2 below the average.
So, answer is it is not necessary that if median is greater than average, there will be more terms above average than below it, specifically in the scenario that there are even number of terms.
Example 16: In a class of 5 students, average weight of the 4 lightest students is 40 kgs, Average weight of the 4 heaviest students is 45 kgs. What is the difference between the maximum and minimum possible average weight overall?
A. 2.8 kgs B.3.2 kgs C.3 kgs D.4 Kgs
A. 2.8 kgs B.3.2 kgs C.3 kgs D.4 Kgs
Solution: Let’s say that the students are named a, b, c, d and e, in increasing order of weights. The average of a, b, c and d is 40 kg, whereas the average of b, c, d and e is 45 kg.
The sum of a, b, c and d is 160 kg, and the sum of b, c, d and e is 180 kg.
What is the total weight of all the students?
There are two ways of looking at this.
a) 160 + e
b) 180 + a
or, e is 20 more than a.
Now, the total weight is 160 + e. So, the highest value of e will correspond to the highest possible average. The highest possible value of e occurs when it is 20 higher than the highest possible value for a, which is 40 (a is lightest and here we assume that all a, b, c and d is 40).
So, the highest possible average is : (160 + 60) / 5 = 44
The sum of a, b, c and d is 160 kg, and the sum of b, c, d and e is 180 kg.
What is the total weight of all the students?
There are two ways of looking at this.
a) 160 + e
b) 180 + a
or, e is 20 more than a.
Now, the total weight is 160 + e. So, the highest value of e will correspond to the highest possible average. The highest possible value of e occurs when it is 20 higher than the highest possible value for a, which is 40 (a is lightest and here we assume that all a, b, c and d is 40).
So, the highest possible average is : (160 + 60) / 5 = 44
This will be the case when the weights are 40 kgs, 40kgs, 40 kgs, 40 kgs and 60 kgs.
Conversely, the least possible value for the average occurs when a is the least. This happens when e is the least too (since a is 20 less than e).
The least possible value for e is 45 = 180/4
The least possible value for e is 45 = 180/4
So, the least possible value for a would be 25.
The least possible average = (180 + 25) / 5 = 41 Kg
The least possible average = (180 + 25) / 5 = 41 Kg
This will be the case when the weights are 25 kgs, 45kgs, 45 kgs, 45 kgs and 45 kgs. So, the difference between maximum possible and minimum possible average = 3 kgs.
Answer choice (c)
Example 17: The average of 5 distinct positive integers if 33. What are the maximum and minimum possible values of the median of the 5 numbers if the average of the three largest numbers within this set is 39?
Solution: Let the numbers be a, b, c, d, e in ascending order. a + b + c + d + e = 165. Average of the three largest numbers is 39, so c + d + e = 117, or a + b = 48.
We need to find the maximum and minimum possible values of c.
We need to find the maximum and minimum possible values of c.
For minimum value, a and b have to be minimum. a + b = 48. Let us assume a = 23, b = 25, ca can be as low as 26.
23, 25, 26, 45, 46 is a possible sequence that satisfies the conditions.
23, 25, 26, 45, 46 is a possible sequence that satisfies the conditions.
For maximum value, we need d + e to be minimum as c + d + e = 117. We can have c = 38, d = 39 and e = 40. Or, the maximum value c can take = 38.
23, 25, 38, 39, 40 is a possible sequence that satisfies the conditions specified.
Example 18: Consider 4 numbers a, b, c and d. Ram figures that the smallest average of some three of these four numbers is 30 and the largest average of some three of these 4 is 40. What is the range of values the average of all 4 numbers can take?
Solution: We can assume a, b, c and d are in ascending order (with the caveat that numbers can be equal to each other)
a + b + c = 90
b + c + d = 120
We need to find the maximum and minimum value of a + b + c + d.
a + b + c + d = 120 + a. So, this will be minimum when a is minimum. Given a + b + c = 90. a is minimum when b + c is maximum. If b + c is maximum, d should be minimum.
Given that b + c + d = 120, the minimum value d can take is 40 as d cannot be less than b or c.
The highest value b + c can take is 80, when b = c = d = 40. When b = c = d = 40, a = 10.
a + b + c + d = 130. Average = 32.5
a + b + c = 90
b + c + d = 120
We need to find the maximum and minimum value of a + b + c + d.
a + b + c + d = 120 + a. So, this will be minimum when a is minimum. Given a + b + c = 90. a is minimum when b + c is maximum. If b + c is maximum, d should be minimum.
Given that b + c + d = 120, the minimum value d can take is 40 as d cannot be less than b or c.
The highest value b + c can take is 80, when b = c = d = 40. When b = c = d = 40, a = 10.
a + b + c + d = 130. Average = 32.5
Similarly, a + b + c + d = 90 + d. So, this will be maximum when d is maximum.
Given b + c + d = 120. d is maximum when b + c is minimum. If b + c is minimum, a should be maximum.
Given that a + b + c = 90, the maximum value a can take is 30 as a cannot be greater than b or c. The lowest value b + c can take is 60, when a = b = c = 30. When a = b = c = 30, d = 60.
a + b + c + d = 150. Average = 37.5
so, the average has to range from 32.5 to 37.5
Given b + c + d = 120. d is maximum when b + c is minimum. If b + c is minimum, a should be maximum.
Given that a + b + c = 90, the maximum value a can take is 30 as a cannot be greater than b or c. The lowest value b + c can take is 60, when a = b = c = 30. When a = b = c = 30, d = 60.
a + b + c + d = 150. Average = 37.5
so, the average has to range from 32.5 to 37.5
Previous year XAT questions:
Example 19: (XAT’12): Ramesh analyzed the monthly salary figures of five vice presidents of his company. All the salary figures are in integer lakhs. The mean and the median salary figures are Rs. 5 lakhs, and the only mode is Rs 8 lakhs. Which of the options below is the sum (in Rs. lakhs) of the highest and the lowest salaries?
Solution: Let us say the five salaries are s1, s2, s3, s4 and s5. As the median is 5 (s3), two people got salary more than or equal to 5 and two got less than or equal to 5. As the mode is 8, 8 should have the highest frequency. Since, 8>5, s4 and s5 are equal to 8. We also know that the mean is 5, so
S1 + s2 +s3 + s4 + s5 = 5×5 =25
S1 + s2 + 5 + 8 + 8 = 25
S1 + s2 = 4.
Since, the salaries are integer lakhs, we have two possibilities for s1 and s2, either both can be equal to 2 or s1 =1 and s2 = 3. If both s1 and s2 becomes 2, then 2 also becomes the mode, but the question states that there is only one mode, which is 8. Thus, we will go with second possibility, s1 = 1 and s2 = 3.
We want the sum of highest and lowest salaries. Highest salary is 8 lakhs, lowest salary is 1 lakh, so the sum is 9 lakhs.
Example 20: (XAT’11): In a list of seven integers, one integer denoted as x is unknown. The other six integers are 20, 4, 10, 4, 8 and 4. If the mean, median and mode of these 7 integers are arranged in increasing order, they form an arithmetic progression. The sum of all possible values of x is:
(1)26 (2) 32 (3) 34 (4) 38 (5) 40 M3u converter for mac.
Solution: Let us arrange the six known integers in ascending order, {4,4,4,8,10,20}. As 4 occurs 3 times, irrespective of the value of x, the Mode is 4. Mean = 50+x/7
The possibilies of median are:
- ‘4’ if x is less than or equal to 4,
- ‘8’ if x is less than or equal to 8,
- ‘x’ if x lies between 4 and 8.
As we know ‘x’ is an integer, the median will be an integer( either 4,8 or x). Since, 4 is already mode, median cannot be 4. So, we are left with two cases.
Case b: x is between 4 and 8.
X could be 5,6,7. The value of x becomes median in this case. As the mean has to be an integer to form an AP, this is possible for x = 6 only. Then mean = 8. Mean, median and mode when arranged in increasing order forms an AP. Thus, x = 6 is a possible solution.
Case c: x is more than or equal to 8
In this case the median will be 8. The difference between mode and median is 4 in this case. As the mean will be more than 6, the possible value of mean is 12. To get the value of mean as 12, x = 34.
Thus, the sum of all possible values of x = 6 + 34 = 40.
The concepts discussed in this post are very basic but questions can be tricky with the language. If you are thorough with the basic concepts and definitions, then the question can be solved very easily.
To summarize, Mean, Median and Mode is a fairly easy topic in CAT. The questions on mean, mode, median are to be solved going by the basic definition or formula of the concept. Most of the questions would be related to above pattern. If you are thorough with the basic concepts and definitions, If you can understand the above mentioned examples and solutions, you are all set to rock the exams.
You can also see:
Ratio and Proportion – Concepts, Properties, and CAT Questions
Boats and Streams – Tips Tricks and Questions for CAT Exam
Averages Concepts from Arithmetic – How to apply in CAT Questions?
Ratio and Proportion – Concepts, Properties, and CAT Questions
Boats and Streams – Tips Tricks and Questions for CAT Exam
Averages Concepts from Arithmetic – How to apply in CAT Questions?
Online Coaching Course for CAT 2020
a) 900+ Videos covering entire CAT syllabus
b) 2 Live Classes (online) every week for doubt clarification
c) Study Material & PDFs for practice and understanding
d) 10 Mock Tests in the latest pattern
e) Previous Year Questions solved on video
b) 2 Live Classes (online) every week for doubt clarification
c) Study Material & PDFs for practice and understanding
d) 10 Mock Tests in the latest pattern
e) Previous Year Questions solved on video
Javascript on your browser is not enabled.
4.1/5(10votes )
- want your help
- remove a number from the data set so the mean is 20.
10, 12, 20, 23, 25 - the example of mode ,ans is wrong . the ans will be 3
Leave a Reply
This site uses Akismet to reduce spam. Learn how your comment data is processed.