Given the function:
\[ f(x) = |x - a| + |x - 100| + |x - (a + 50)| \] We aim to determine the value of \( a \) that maximizes \( f(x) \).
We consider three scenarios for \( x \) relative to \( a \) and \( a + 50 \):
We compare the maximum values derived from each case: - In Case 1, the maximum value is \( 2a + 150 \). - In Case 2, \( f(x) \) reaches its maximum at \( x = a \). - In Case 3, the maximum value occurs at \( x = 100 \).
To maximize \( f(x) \), we must maximize the expression \( 2a + 150 \), which occurs when \( a = 100 \).
The maximum value of \( f(x) \) is 100, attained when \( a = 100 \).
The correct answer is \( \boxed{100} \).