Simple examples of subject-verb agreement are "The dog barks often" and "The dogs bark often." The singular noun "dog" uses the singular verb "barks," while the plural noun "dogs" uses the plural verb "bark."
Examples of subject-verb agreement when there is a compound subject are "The dog and the cat are for sale," "The dog or the cat is for sale," "The dog or the cats are for sale" and "The dogs or the cat is for sale." When compound subjects join with "and," the verb is plural. When compound subjects join with "or," the verb matches in number the subject closest to it. If that subject is singular, so is the verb. If it is plural, the verb is plural.
Collective nouns, which are those that imply more than one person or thing, pose another issue. When the parts of a collective noun work as a single unit, the noun is singular and takes a singular verb. Examples are "The couple is moving to Florida," "The class is taking a test" and "The team is practicing today."
Knowing the number of indefinite pronouns is important for subject-verb agreement. "Everyone" and "everybody" are singular pronouns and require singular verbs. An example is "Everybody is here."
When a prepositional phrase or any other group of words separates the subject and verb, those phrases should be ignored in determining subject-verb agreement. In the sentence "All the dogs in the neighborhood are barking," "dogs" and "are" must agree. The fact that "neighborhood" is singular does not matter.