Let's denote the number of men in the election before the new man entered as \( n \) and the total age of those men as \( S \).
Given that the average age of the men before the new man entered is 42, we have:
\[ \frac{S}{n} = 42 \implies S = 42n \]
After the new man enters, the average age becomes 40. The new total number of men is \( n + 1 \), and the total age now becomes \( S + x \), where \( x \) is the age of the new man. We can express the average age after the new man enters as:
\[ \frac{S + x}{n + 1} = 40 \]
Now, substituting \( S \) from the first equation into the second equation, we have:
\[ \frac{42n + x}{n + 1} = 40 \]
Cross-multiplying gives:
\[ 42n + x = 40(n + 1) \]
Expanding the right side, we get:
\[ 42n + x = 40n + 40 \]
Now, rearranging the equation to solve for \( x \) (the age of the new man):
\[ x = 40n + 40 - 42n \] \[ x = -2n + 40 \]
This indicates that the age \( x \) depends on \( n \), the number of men before the new man entered.
To find the man's age, we observe the situation:
- If \( n \) is 1, the new man's age would be \( -2(1) + 40 = 38 \).
- If \( n \) is 2, the new man's age would be \( -2(2) + 40 = 36 \).
- If \( n \) is 3, the new man's age would be \( -2(3) + 40 = 34 \).
And so on.
However, we can find a specific value by noting that the new average value dropped from 42 to 40. This implies that the new man's age is below the previous average in order to lower the average.
To find the specific age that keeps average age at 40, we set values of \( n \). A reasonable assumption is to set \( n = 10 \):
\[ x = -2(10) + 40 = 20 \]
In that case, the age of the man who entered is 20 if the number of men initially was 10.
Thus, generally, if you wish to maintain the calculations generically, the age of the new man is calculated by:
\[ \text{Age of new man} = 40 - 2n \]
So you can determine specific ages based on the value of \( n \).