Translate the following inference to logic notation: If Robert writes a letter, then it is cloudy. If it is cloudy, then Robert is writing a letter. Karen is excited if and only if it is cloudy. Therefore if Robert writes a letter, then Karen is excited.
p -> q. q -> p. r <-> q. Therefore p -> r.