Olivia spent w dollars at a supermarket. If she has x dollars left with her How much money did she have initially?
Olivia spent w dollars at a supermarket. 

That means she had w dollars to spend at the supermarket. 

Now she has x dollars left with her. 

That means she had w + x dollars with her in total.