The two actions, (a) and (b), are called counterclaims. Counterclaims are legal claims filed by a defendant in response to a lawsuit brought against them by a plaintiff. In a counterclaim, the defendant becomes the plaintiff, and the plaintiff becomes the defendant. The defendant asserts their own legal claims against the plaintiff and may also assert claims against other parties, such as co-defendants. The purpose of a counterclaim is to allow all parties involved in a legal dispute to have their claims heard and decided in one proceeding, rather than in separate lawsuits.