Arsenal finished their Europa League Group B campaign with a 100% record as they overcame Dundalk in muddy conditions at the Aviva Stadium.
Eddie Nketiah gave the Gunners the lead when he clipped his shot past Gary Rogers after an error by Andrew Boyle.
Mohamed Elneny doubled the advantage with a superb strike before Jordan Flores made it 2-1 with an angled shot.
Joe Willock and Folarin Balogun scored late on for the Gunners before Sean Hoare grabbed a second for Dundalk.