General Query - For Loop used in 331/3

Hello Guys,
This question is regarding 3rd mission of 331.
https://app.dataquest.io/m/331/python-data-analysis-basics/3/converting-ages-to-decades.

To solve this, i could see for loop is iterated over age, i.e. "for age in final_ages: ". However, till now we used to do iteration as “for row in moma:” & then assigning row number to required assignment, for an example date = row[6], birth = row[3] as in previous exercise.
Can anyone explain how “for age in final_ages:” working ? Seems i am facing proper understanding problem.

1 Like

Hi @deodattatijare

You have already done your iteration on moma and stored the age into the final_ages list in the previous mission. So, in this mission, no need to repeat that process because final_ages is already present. You can use it for creating decades corresponding to each age.

1 Like