Former champions Algeria crashed out of the Africa Cup of Nations on Tuesday after losing 1-0 to Mauritania, who are 75 places lower in the world rankings.
The underdogs, Mauritania will now fill one of four places reserved for third-placed finishers in the group stage.
Meanwhile, Angola are through to the last 16 of the Africa Cup of Nations as winners of their group after a 2-0 victory over Burkina Faso late yesterday.
Both sides already are through to the last 16 from Group D before kick-off in Yamoussoukro, but with Burkina Faso finishing second, it means they play against the winners of Group E, which could be Mali, South Africa or Namibia.