I recently did a justice course online which is run by Michael Sandel. On of the cases was The Queen vs Dudley and Stephens (1884), where two men on a lifeboat kill the third person in order to survive themselves. They were later found to be guilty. However, the case cites some examples of justified homicide:
…in the case often put by casuists, of two drowning men on a plank large enough to support one only, and one thrusting the other off, the survivor could not be subjected to legal punishment. In the American case of The United States v. Holmes, the proposition that a passenger on board a vessel may be thrown overboard to save the others is sanctioned.
I was just wondering, are these two cases in accordance with moral law? Or do they violate Church teaching?