Given:
Sam is 8 years older than Beth.
Four years ago Sam was twice as old as Beth.
To find the present age of sam:
Let x be the age of Beth.
So, the age of sam is x+8.
Then,
x+8-4=2(x-4)
x+4=2x-8
x=12
Hence, the age of Beth is 12.
Therefore, the present age of sam is 20.