Pokemon Shuffle is largely based on Battle Trozei. In Trozei Ditto is available and works as a wildcard, so it matches with any other Pokemon. If you have two Dragonite and a Ditto in a row, that counts as a match of 3 Dragonite.
Basically they copied the programming for Ditto from Trozei, though it hasn't been released in Shuffle. This means that for the competitions using Ditto gets you pretty much endless combos. Palkia's data is also there in the game (because it's in the Pokedex next to Dialga) so people hacked that in because it's a powerful water type against Charizard.
In short: they hacked to get themselves a higher score. All those people were excluded from the competition.