I found the following in the batbook (page 329):
The sendmail program then tries to deliver the message to each host in the list of MX
hosts, one at a time, until one of them succeeds or until they all fail. The value of an
MX record contains a cost value (also called preference) and the hostname to which
to connect. All MX hosts at a given cost (preference) are tried before any at a higher
cost (lower preference) are tried (that is, all the 5’s are tried, for example, before any
6’s). Beginning withV8.8 sendmail, if a host in the list returns a 5xy SMTP code (permanent
failure), the effect is to cause subsequent MX hosts to be ignored. (Connect
failures are the exception, in that they continue to the next MX host as usual.) Most
temporary errors cause sendmail to try the next MX record. If sendmail exhausts the
MX list with neither success nor a permanent error, the temporary error will cause
the message to be queued for a later attempt.