The study of the structure of sentences and phrases, or the way people arrange their words so they make sense when they speak, is known as syntax. Every language has fundamental syntax rules, which together with morphological rules make up the grammar of each language.
The difference between "Emmie walked the dog" and "The dog walked Emmie" is an illustration of how syntax affects language. The words must be in the correct order for the sentence to convey the intended meaning since the arrangement of the phrases is not always random.
4. Semantics & Pragmatics
In general, semantics is concerned with how statements are understood. A person who analyses semantics has an interest in words along with what they indicate or point to in the real world.
As an example, someone yelling "Fire!" has a totally different meaning if they're on the receiving end of a seven-gun salute than it would if they are sitting in a full movie theatre. Pragmatics is an expansive field that explores how the context of a phrase influences meaning.