Answer:

Step-by-step explanation:
Hello there!
In this case, since the Lewis dot structures are able to show the number bonds, required atoms and valence electrons of each bonding species, it is necessary to keep in mind that potassium has one valence electron, iodine has seven, magnesium has two and fluorine has seven; therefore, we can infer that the compound KI has one bond whereby iodine is able to attain the octet and the compound MgF needs two fluoride ions to fill out those two valence electrons of magnesium to obtain MgF₂, since the Lewis structures are:

Therefore, the chemical formulas are just:

Best regards!