Answer :
Covalent compound : It is defined as the compound which is formed by the sharing of electrons between the atoms forming a compound.
The covalent compound are usually formed when two non-metals react.
Ionic compound : It is defined as the compound which is formed when electron gets transferred from one atom to another atom.
All the polyatomic ions always form an ionic compound.
Polyatomic ions : It is a charged species that composed of two or more atoms and these charged species are bonded by the covalent bond.
For the given options:
Option A:  
This compound is formed by the combination of potassium,  which is a metal and
 which is a metal and  ion which is a polyatomic ion. Thus, it will form an ionic compound.
 ion which is a polyatomic ion. Thus, it will form an ionic compound.
Option B:  
This compound is formed by the combination of magnesium,  which is a metal and
 which is a metal and  ion which is a polyatomic ion. Thus, it will form an ionic compound.
 ion which is a polyatomic ion. Thus, it will form an ionic compound.
Option C:  
Hydrogen and sulfur, both are non-metals and they will form a covalent compound.
Option D:  
This compound is formed by the combination of silver,  which is a metal and sulfur,
 which is a metal and sulfur,  which is a non-metal. Thus, it will form an ionic compound.
 which is a non-metal. Thus, it will form an ionic compound.
Option E:  
Nitrogen and chlorine, both are non-metals and they will form a covalent compound.
Option F:  
This compound is formed by the combination of cobalt,  which is a metal and
 which is a metal and  ion which is a polyatomic ion. Thus, it will form an ionic compound.
 ion which is a polyatomic ion. Thus, it will form an ionic compound.