The crab understood the motive of the crane and used his wit to get out of the situation.