you are 100,000 feet above planet B and the ground range to your horizon point is 400 miles. What is the radius of planet B?

The satellite, Earth center and horizon tangent point form a right triangle. The Pythagorean theorem says

R^2 + x^2 = (R + h)^2

h is the altitude and x is the range. R is the earth radius

Solve for R.

x^2 = 2hR + h^2

R = (x^2-h^2)/(2h)