Let us assume age of zia = x years.
Raj is three years older than Zia.
Therefore, Raj age = (x+3).
Sum of squares of their ages = 369.
Therefore, we can set an equation as :

Let us expand
now.


Subtracting 369 from both sides


Factoring quadratic


We can't take negative value for age.
Therefore, Zia's age is 12 years and Raj age is 12+3 = 15 years.