The most accurate response is:
The remaining materials from the sun's formation clumped together due to gravity.
This explanation aligns with the widely accepted nebular hypothesis, which suggests that the planets formed from a rotating disk of gas and dust surrounding the newly formed sun. Gravity caused the material to clump together, leading to the formation of the planets.