Solution:
Concept: The mean of n observations is xˉ=nsum of the observations. Turned round, the sum of the observations =n×xˉ. The median is the middle value of the data after it is arranged in order. For n observations: if n is odd, the median is the (2n+1)th observation; if n is even, it is the mean of the (2n)th and (2n+1)th observations.
Step 1 — Mean of team A.
Add the 7 heights and divide by 7.
ΣxA=180+178+176+181+190+175+187=1267
xˉA=71267=181cm
Step 2 — Mean of team B.
Do the same for team B.
ΣxB=174+175+190+179+178+185+177=1258
xˉB=71258≈179.71cm
Step 3 — Compare.
181 cm is more than 179.71 cm, so team A had the greater average height.
Step 4 — Medians.
Team A in order: 175, 176, 178, 180, 181, 187, 190; team B in order: 174, 175, 177, 178, 179, 185, 190. Each team has 7 heights, so the median is the 4th value: 180 cm for team A and 178 cm for team B.
Watch out: Arrange each team's heights in order before picking the 4th value.
Therefore, team A had the greater average height (181 cm against about 179.71 cm); the medians are 180 cm for team A and 178 cm for team B.