Algeria is heading through to the AFCON 2019 semi-final after his Algeria side defeated Ivory Coast on Thursday evening.
Galatasaray and former West Ham United midfielder Sofiane Feghouli opened the scoring after just 20 minutes, attacking a low cross inside the area.
But Algerian dreams were dented midway through the second half with Aston Villa striker Jonathan Kodja striking to send the game into extra time and penalties.
Algeria won 4-3 on penalties with Islam Slimani scoring his spot-kick, taking his side's second.
Wilfried Bony and Geoffrey Saray Die missed for Ivory Coast, allowing Algeria to progress through to the penultimate stage.
The winner of that one will face either Senegal or the winner of Madagascar and Tunisia, who face off in the last quarter final on Thursday evening.
Slimani and Ndidi's progress in the competition means, of course, they will remain in Egypt and as expected, they will miss the majority of pre-season, returning in early August ahead of the new campaign.