Iraq's parliament on Thursday elected veteran Kurdish politician Fuad Masum as federal president, a move that paves the way for the much-delayed formation of a new government.