Answer
a) Mg=1, Cl=2
b) Na=1, N=1, O=3
c) Ca=1, N=2, O=4
d) Sr= 1, O=2, H=2
Work Step by Step
To find the number of each type of atom in a compound, we need to look at the subscript, which is written after the symbol of an atom.
If there is no subscript written, then it is taken to be 1.
If the element of a particular compound is enclosed in a bracket (forms polyatomic ion), then we need to multiply the subscript of individual atoms by the subscript after the bracket.
For example, in $Ca(NO_{2})_{2}$
Number of Ca atoms = 1
Number of N atoms = 1$\times$2 =2
Number of O atoms = 2$\times$2 = 4.