Let son 's current age is x and father 's current age is y.
Now,where does the (y−x) term come from?
It says 'when the son will be as old as the father is today, which means that the son has to age a certain amount of years. How many years does he have to age?
The difference between his current age and his father 's current age.
For example, if the son was 10 and the father was 40, it would take the son 30 years (or y−x=40−10) to reach his current age. In the meantime, the father would age the same amount (y−x=40−10=30 years).
[Father 's new age] + [Son 's new age] =126
[y+(y−x)]+[(x+(y−x))]=126
⇒2y−x+y=126
∴3y−x=126 ..........(1)
[Father 's previous age] + [Son 's previous age]=38
[y−(y−x)]+[x−(y−x)]=38
⇒x+x−y+x=38
⇒3x−y=38
∴y=3x−38 .........(2)
Now sub eqn(2) into equation(1)
⇒3(3x−38)−x=126
⇒9x−114−x=126
⇒8x=240
∴x=30
Now y=3x−38
⇒y=3(30)−38
∴y=52
The son is 30 years old, and the father is 52 years old.