Which of the following statements about the median is true?
A) The median is always affected by extreme values or outliers.
B) The median divides the dataset into two equal halves.
C)The median represents the most frequently occurring value in the dataset.
D) The median is calculated using the sum of all data values.