arifs age = 12
father's age = 40
let after 'x' years father's age will be twice that of arifs age at that time
therefore
arifs age after x years = 12 + x
father's age after x years = 40 + x
after x years father will twice as old as arif at that time => (12 + x) * 2 = 40 + x
x = 40 -24 = 16