contestada

What are the rules that a magistrate, judge, or attorney uses when interpreting a writing that claims to be a contract?