Which of the following is not an element of a valid contractual agreement?
A. All parties must have legal capacity.
B. The purpose of the agreement must be legal.
C. It must be an exchange of goods or services.
D. The agreement must be in writing.