Translate the following inference to logic notation: Charles is not running. Charles is running if and only if Barbara is a soldier. Barbara is a soldier. Therefore David is a sailor.
~p. p <-> q. q. Therefore r.