Interaction of half-quantized vortices in two-component Bose-Einstein condensates