Attraction of semiconductor nanowires: an in situ observation