We have that
Sheri's age=x
terry's age=y
in 20 years
x+20 =y equation 1
in 10 years
y+10=2*x equation 2
resolving
y=x+20 equation 1
y=2*x-10 equation 2
x+20 =2*x-10
2*x-x=20+10
x=30
y=x+20--------------y=30+20=50
Sheri's age=x------------------30 years
terry's age=y-------------------50 years