Input (grade 2): Mary II then ruled jointly with her husband, William III.
Output (grade 3): Mary II ruled together with her husband, William III.