Napoli midfielder Adam Ounas scored twice and picked up an assist on his first appearance at the Africa Cup of Nations as Algeria maintained their 100% record with victory over Tanzania.
Ounas set-up Leicester striker Islam Slimani for the opener before netting twice in a dominant first-half display.
Algeria, who finish top of Group C, were already through to the last 16 with wins in their opening two games.
They will face one of the best third-placed teams in the next round.
With qualification already secured, Algeria coach Djamel Belmadi made nine changes to the starting XI – handing a start to Slimani, who has been kept out of the team by in-form Al Sadd striker Baghdad Bounedjah.
And Slimani took his chance after half an hour, netting his 27th international goal on his 61st appearance following a wonderful reverse through ball from Ounas.
That was the breakthrough Algeria were searching for and Ounas made it 2-0 five minutes later after linking up with Slimani on the edge of the box to score his first international goal on just his seventh appearance.
Tanzania, who had defended well for the first half an hour, could do nothing to prevent a third on the stroke of half-time as Slimani’s threaded pass found Ounas again and the midfielder coolly rounded the keeper before slotting into an empty net.
Algeria had more chances after the break – Mohamed Salim Fares volleying Ounas’ delivery wide before hitting the outside of the right post from close-range.
Manchester City winger Riyad Mahrez replaced Ounas in the second half but did not make an impact, while substitute Bounedjah wasted a great chance to make it 4-0 when he fired wide late on. Blackpool striker Adi Yussuf also came on for Tanzania in the second half but headed over the bar with minutes to spare.
Tanzania, who were competing in their first Nations Cup since 1980, failed to progress to the knock-out stages and finished bottom of the group with three defeats.