Sadly some information is missing
This would problem will be answered using the concept of momentum. Momentum is the mass times the velocity, where mass is inversely proportional to the velocity. This would mean that an object with greater mass will travel at a much lesser velocity, or vice versa.
Hence, the cart with the smaller mass will accelerate faster.
It’s C magnetic field because with the forces of the magnets pushing against each other it gets the engine to start turning the wheels.