Answer:
Q= Magnesium R= Chlorine
Explanation:
The element Q should be magnesium and R is chlorine.
An ionic compound is a compound that is formed by the combination of a metal and non-metal. Such bonds forms when there is a transfer of electrons from the metals to the non-metals. This leaves a net positive charge on the metal and a negative charge on the non-metal.
The electrostatic attraction leads to the formation of the bond.
 To solve this problem, the hypothetical compound is QR₂
    Mg             Cl
   2 8 2           2 8 7
So, Mg transfers 2 electrons to two atoms of chlorine.
 This leads to the formation of the compound MgCl₂