Original: He was assassinated by a member of the Muslim Brotherhood while in office.
Simplified: He was assassinated by the Muslim Brotherhood while he was Prime Minister.