<p dir="ltr">you could filter record list</p>
<p dir="ltr"><a href="http://hackage.haskell.org/package/base-4.8.1.0/docs/Prelude.html#v:filter">http://hackage.haskell.org/package/base-4.8.1.0/docs/Prelude.html#v:filter</a></p>
<p dir="ltr">\r -> elem (name r) names</p>
<p dir="ltr">then fmap the filtered list to extract age<br>
age <$> list1</p>