Well a basic explanation is that some elements have enough electrons to be considered stable. These elements do not need to react with other elements to gain more electrons. Reactive elements are no where near stable; they respond with other elements in order to become stable. The more unstable, the harsher the reaction is.
Explanation: If a current i is flowing in a wire of length L lying in a region of magnetic field B, then the magnetic force acting on the wire is given by