It's a hard one but I think I got it. At first I was very confused, but it was clear that all that the things those pokemon had in common were that they are all steel types and they all learn magnet rise/flash cannon. Then what I did was comparing the two pokemon that were more alike inside and outside of the list, magneton and magnezone, and tried to use every single of the differences I could find between them until I got it.
/ds steel type,magnetrise,!ironhead