Let's denote the number of years a person spends watching TV as \( x \) and the number of years spent sleeping as \( y \).
According to the problem, we have two pieces of information:
-
The total years spent on sleeping and watching TV is 34 years: \[ x + y = 34 \]
-
The number of years sleeping exceeds the number of years watching TV by 18 years: \[ y = x + 18 \]
Now we can substitute the second equation into the first equation. Replacing \( y \) in the first equation with \( x + 18 \): \[ x + (x + 18) = 34 \]
Combining like terms: \[ 2x + 18 = 34 \]
Now, we'll isolate \( x \) by subtracting 18 from both sides: \[ 2x = 34 - 18 \] \[ 2x = 16 \]
Dividing both sides by 2: \[ x = 8 \]
Now that we have \( x \), we can find \( y \) using the second equation: \[ y = x + 18 \] \[ y = 8 + 18 \] \[ y = 26 \]
Thus, the person will spend:
- 8 years watching TV
- 26 years sleeping
So the final answer is:
The person will spend 8 years watching TV and 26 years sleeping.