1. The dog ran around the house.

----------------------
Does it mean that the dog ran outside the house?
Does it mean he ran here and there in the house? Or does the sentence mean both situations?

The sentence can mean either of those situations.

We usually can tell what is meant by the preceding sentences.

The sentence "The dog ran around the house" can have different interpretations depending on the context. It can mean that the dog ran outside the house, circling the perimeter. In this case, "around" indicates the movement around the exterior of the house.

Alternatively, it can also mean that the dog ran inside the house, moving from room to room or in a chaotic manner. Here, "around" refers to the movement within the interior space.

Without more context, it is not possible to determine definitively which interpretation is correct. It could be either situation, or it could even be both if the dog initially ran outside and then continued running inside the house.