The answer is true.
The close encounter hypothesis, or simply the encounter hypothesis, speculates that the formation of our solar system occurred due to a near collision between our sun and another star. It claims that hot gas was stripped from both the sun and the star, leading to the formation of our planets.