Each member of your team can counter each other's weaknesses (ex. If your team consisted of a Normal-type (which is weak to Fighting) and a Flying-, Psychic- or Fairy-type, the ladder would cover the Normal-type's weakness.).
Metagross is a Steel/Psychic-type and is weak to Fire, Ground, Ghost, and Dark.
Gengar is a Ghost/Poison-type and is weak to Ground, Psychic, Ghost, and Dark.
Primarina is a Water/Fairy-type and is weak to Electric, Grass, and Poison.
Salazzle is a Poison/Fire-type and is weak to Water(2x), Ground(4x), Psychic(2x), and Rock(2x).
Garchomp is a Dragon/Ground-type and is weak to Ice(4x), Dragon(2x), and Fairy(2x).
So, knowing that, we can see that:
Metagross can cover Primarina's weakness to Poison, Salazzle's weakness to Rock, and Garchomp's weaknesses to Ice and Fairy.
Gengar can cover itself and Metagross' weaknesses to Ghost, itself and Salazzle's weaknesses to Psychic, and Garchomp's weakness to Fairy.
Primarina can cover Metagross' weaknesses to Fire, Metagross and Gengar and Salazzle's weaknesses to Ground, Salazzle's weakness to Ground, Metagross and Gengar's weaknesses to Dark, and Garchomp's weakness to itself.
Salazzle can cover Primarina's weakness to Grass and Garchomp's weakness to Ice.
Garchomp can cover its own weakness to itself, Metagross' weakness to Fire, Primarina's weakness to Electric and Poison, and Salazzle's weakness to Rock.
This chart I compiled shows a clearer picture of what I'm saying.
Metagross- Fire, (Primarina or Garchomp) Ground, (Primarina) Ghost, (Gengar) Dark (Primarina).
Gengar- Ground, (Primarina) Psychic, (Gengar) Ghost, (Gengar) Dark (Primarina).
Primarina- Electric, (Garchomp) Grass, (Salazzle or Gengar) Poison (Garchomp or Metagross).
Salazzle- Water, (x) Ground, (Primarina) Psychic, (Gengar) Rock (Metagross, Primarina or Garchomp).
Garchomp- Ice, (Metagross or Salazzle) Dragon, (Garchomp or Primarina) Fairy (Salazzle or Metagross or Gengar).
So, the only weakness not covered for is Salazzle's weakness to Water (In which you need an Electric or Grass type to cover for it). Now you know that you need either Raichu (Alolan), Vikavolt, Magnezone, Jolteon, Lanturn, Togedemaru, Electivire, Golem(Alolan), Emolga, Tapu Koko, and Xurkitree OR Kartana (The rest of the part-Grass-types in SM have a weakness to Flying, which, by type, your team cannot cover for).