Mohamed Morsi elected in a highly competitive race, only to be ousted by the military a year later.