Translate the following inference to logic notation: It is sunny. If Sarah cooks, then it is sunny. It is sunny if and only if Barbara is a scientist. If Barbara were a scientist, then Sarah is cooking. Therefore Barbara is a scientist.
p. q -> p. p <-> r. r -> q. Therefore r.