A Monte Carlo study of effects of chain stiffness and chain ends on dilute solution behavior of polymers. II. Second virial coefficient