Preparation of halogenated hydrocarbons by replacement by halogens of halogen atoms by other halogen atoms {two or more compounds being involved in the reaction the other compound being HX}