2D sprite collisions

How do I code a sprite to stop moving when no longer colliding with another sprite

How to do that is explained in Creating Animated Apps

That's an unusual game mechanic.

Is the other sprite carrying the first sprite?