The correct option is D all of the above
As per Newton's law of gravitation, the gravitational force of attraction between any two bodies is directly proportional to the product of their masses and inversely proportional to the square of the distance between them. Hence, the force of attraction between the two bodies (A, B) depends upon all the three.