Mg's Standard Reduction Potential is -2.37V (Mg+2 + 2Electrons = Mg) and Pb's SRP is -.126V (Pb+2 + 2electrons = Pb). Since Pb has a larger SRP, it is more easily reduced. Since Pb is reduced, it will be in the cathode. Mg's SRP is lower so it is more easily oxidized. Oxidation occurs in the anode. Remember that the two vowels go together (Anode-Oxidation) and the CR goes together (Cathode-Reduction).Basically, the higher the SRP, the more likely it is to be reduced. Therefore, the substance will be the cathode. The lower the SRP, the more likely it is to oxidized. Therefore, the substance will be the anode.