Which sentence best corrects the pronoun with the unclear antecedent?

Martin told John that he was late for class.


"You're late for class," Martin told John.

"Martin and John, you're late for class."

John told Martin that he was late for class.

When Martin told John, he was late for class.