Acylation of amines using different carboxylic derivatives produces amides. Acylation replaces the leaving group attached to the carbonyl carbon with an amino group. First, the nucleophilic amine approaches the carbonyl carbon to form a tetrahedral intermediate. A subsequent loss of the leaving group reconstructs the carbonyl bond. Finally, another amine molecule functions as the Bronsted base and abstracts hydrogen from the protonated amide, neutralizing it to a free amide. Acylation, therefore, uses two equivalents of amines: the first equivalent acts as a nucleophile, and the second equivalent functions as a base. Amides are stabilized by resonance. The positively charged nitrogen atom makes the amides less nucleophilic, eliminating polyacylation. Amides are also less basic. This makes acylation useful in electrophilic aromatic substitutions. To understand this, consider the bromination of aniline. Since an amino group is strongly activating, direct bromination gives a tribrominated product. If instead, the amino group is first acylated and then brominated, a monobrominated product can be obtained.