  Assuming that the number densities of heavy flavor in hadron gas and in QGP
are same at $T_c$, we obtain the effective mass of heavy quark at $T_c$ from
the comparison with the hadron resonance gas model which well describes
particle yield in heavy-ion collisions. We find that charm quark mass at
vanishing baryon chemical potential is around 1.8 GeV which is much heavier
than QCD bare mass and close to $D$ meson mass. The mass slightly increases
with increasing baryon chemical potential and then decreases. On the other
hand, anticharm quark mass constantly decreases with increasing baryon chemical
potential. Bottom quark mass has a similar pattern. Extending the hadron
resonance gas model to a bit higher temperature beyond $T_c$, the effective
masses of charm and bottom quarks decrease with increasing temperature.
