But do you know for sure that those people have public profiles? You are making quite an assumption by implying that this data is public.
I believe that exposing people's personal information without their knowledge or consent, however trivial or helpful as a means to an end, isn't the right thing to do.