Simplified loop to doseq